<commit_before><!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="utf-8">
		<title>three.js examples</title>
		<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
		<link rel="shortcut icon" href="../files/favicon.ico" />
		<link rel="stylesheet" type="text/css" href="../files/main.css">
	</head>
	<body>

		<div id="panel">

			<div id="header">
				<h1><a href="https://threejs.org">three.js</a></h1>

				<div id="sections">
					<a href="../docs/index.html#manual/introduction/Creating-a-scene">docs</a>
					<span class="selected">examples</span>
				</div>

				<div id="expandButton"></div>
			</div>

			<div id="panelScrim"></div>

			<div id="contentWrapper">

				<div id="inputWrapper">
					<input placeholder="" type="text" id="filterInput" autocorrect="off" autocapitalize="off" spellcheck="false" />
					<div id="exitSearchButton"></div>
				</div>

				<div id="content">
					<img id="previewsToggler" src="./files/thumbnails.svg" width="20" height="20" />
				</div>
			</div>

		</div>

		<iframe id="viewer" name="viewer" allowfullscreen allowvr onmousewheel=""></iframe>

		<a id="button" target="_blank"><img src="../files/ic_code_black_24dp.svg"></a>

		<script>

		const panel = document.getElementById( 'panel' );
		const content = document.getElementById( 'content' );
		const viewer = document.getElementById( 'viewer' );
		const filterInput = document.getElementById( 'filterInput' );
		const exitSearchButton = document.getElementById( 'exitSearchButton' );
		const expandButton = document.getElementById( 'expandButton' );
		const viewSrcButton = document.getElementById( 'button' );
		const panelScrim = document.getElementById( 'panelScrim' );

		const previewsToggler = document.getElementById( 'previewsToggler' );

		const links = {};
		const validRedirects = new Map();
		const container = document.createElement( 'div' );

		let selected = null;

		Promise.all( [
			fetch( 'files.json' ).then( response => response.json() ),
			fetch( 'tags.json' ).then( response => response.json() )
		] ).then( ( json ) => {

			init( json[ 0 ], json[ 1 ] );

		} );

		function init( files, tags ) {

			content.appendChild( container );

			viewSrcButton.style.display = 'none';

			for ( const key in files ) {

				const section = files[ key ];

				const header = document.createElement( 'h2' );
				header.textContent = key;
				header.setAttribute( 'data-category', key );
				container.appendChild( header );

				for ( let i = 0; i < section.length; i ++ ) {

					const file = section[ i ];

					const link = createLink( file );
					container.appendChild( link );

					links[ file ] = link;
					validRedirects.set( file, file + '.html' );

				}

			}<commit_msg>Examples: Use async/await instead of promises.<commit_after><!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="utf-8">
		<title>three.js examples</title>
		<meta name="viewport" content="width=device-width, user-scalable=no, minimum-scale=1.0, maximum-scale=1.0">
		<link rel="shortcut icon" href="../files/favicon.ico" />
		<link rel="stylesheet" type="text/css" href="../files/main.css">
	</head>
	<body>

		<div id="panel">

			<div id="header">
				<h1><a href="https://threejs.org">three.js</a></h1>

				<div id="sections">
					<a href="../docs/index.html#manual/introduction/Creating-a-scene">docs</a>
					<span class="selected">examples</span>
				</div>

				<div id="expandButton"></div>
			</div>

			<div id="panelScrim"></div>

			<div id="contentWrapper">

				<div id="inputWrapper">
					<input placeholder="" type="text" id="filterInput" autocorrect="off" autocapitalize="off" spellcheck="false" />
					<div id="exitSearchButton"></div>
				</div>

				<div id="content">
					<img id="previewsToggler" src="./files/thumbnails.svg" width="20" height="20" />
				</div>
			</div>

		</div>

		<iframe id="viewer" name="viewer" allowfullscreen allowvr onmousewheel=""></iframe>

		<a id="button" target="_blank"><img src="../files/ic_code_black_24dp.svg"></a>

		<script>

		const panel = document.getElementById( 'panel' );
		const content = document.getElementById( 'content' );
		const viewer = document.getElementById( 'viewer' );
		const filterInput = document.getElementById( 'filterInput' );
		const exitSearchButton = document.getElementById( 'exitSearchButton' );
		const expandButton = document.getElementById( 'expandButton' );
		const viewSrcButton = document.getElementById( 'button' );
		const panelScrim = document.getElementById( 'panelScrim' );

		const previewsToggler = document.getElementById( 'previewsToggler' );

		const links = {};
		const validRedirects = new Map();
		const container = document.createElement( 'div' );

		let selected = null;

		init();

		async function init() {

			content.appendChild( container );

			viewSrcButton.style.display = 'none';

			const files = await ( await fetch( 'files.json' ) ).json();
			const tags = await ( await fetch( 'tags.json' ) ).json();

			for ( const key in files ) {

				const section = files[ key ];

				const header = document.createElement( 'h2' );
				header.textContent = key;
				header.setAttribute( 'data-category', key );
				container.appendChild( header );

				for ( let i = 0; i < section.length; i ++ ) {

					const file = section[ i ];

					const link = createLink( file );
					container.appendChild( link );

					links[ file ] = link;
					validRedirects.set( file, file + '.html' );

				}

			}
{'fraction_non_alphanumeric': 0.17292274052478135, 'fraction_numerical': 0.0058309037900874635, 'mean_word_length': 3.6914529914529917, 'pattern_counts': {'":': 0, '<': 95, '<?xml version=': 0, '>': 96, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2314386', 'n_tokens_mistral': 2067, 'n_tokens_neox': 1702, 'n_words': 395}