src/vs/workbench/contrib/notebook/browser/contrib/codeRenderer/codeRenderer.ts/NotebookCodeRendererContribution/constructor
class NotebookCodeRendererContribution:	constructor(@IModeService _modeService: IModeService) {
		super();

		const registeredMimeTypes = new Map();
		const registerCodeRendererContrib = (mimeType: string, languageId: string) => {
			if (registeredMimeTypes.has(mimeType)) {
				return;
			}

			OutputRendererRegistry.registerOutputTransform(class extends CodeRendererContrib {
				getMimetypes() {
					return [mimeType];
				}

				render(output: ICellOutputViewModel, item: IOutputItemDto, container: HTMLElement): IRenderOutput {
					const str = getStringValue(item);
					return this._render(output, container, str, languageId);
				}
			});

			registeredMimeTypes.set(mimeType, true);
		};

		_modeService.getRegisteredModes().forEach(id => {
			registerCodeRendererContrib(`text/x-${id}`, id);
		});

		this._register(_modeService.onDidCreateMode((e) => {
			const id = e.getId();
			registerCodeRendererContrib(`text/x-${id}`, id);
		}));

		registerCodeRendererContrib('application/json', 'json');
	}