diff --git a/tutorial_data/scripts/server.js b/tutorial_data/scripts/server.js new file mode 100644 index 0000000000000000000000000000000000000000..19f0d05e7298aa7370859c2ee06245d580816ed4 --- /dev/null +++ b/tutorial_data/scripts/server.js @@ -0,0 +1,26 @@ +const express = require('express') +const server = express() +const path = require('path') + +server.use(express.static(__dirname + '/public')) + +server.use( + '/build/', + express.static(path.join( + __dirname, + 'node_modules/three/build' + )) +) + +server.use( + '/jsm/', + express.static(path.join( + __dirname, + 'node_modules/three/examples/jsm' + )) +) + +server.listen( + 1337, + () => console.log('http://localhost:1337') +) \ No newline at end of file