Use rollup typescript plugin
This commit is contained in:
parent
fa100d4268
commit
8bda527684
|
@ -1,8 +1,10 @@
|
||||||
dummykey.crt
|
/.rollup.cache/
|
||||||
dummykey.key
|
/_site
|
||||||
dummykey.pem
|
/dummykey.crt
|
||||||
index.js
|
/dummykey.key
|
||||||
index.js.map
|
/dummykey.pem
|
||||||
|
/index.js
|
||||||
|
/index.js.map
|
||||||
/lib
|
/lib
|
||||||
/node_modules
|
/node_modules
|
||||||
/_site
|
/tsconfig.tsbuildinfo
|
||||||
|
|
|
@ -3,11 +3,9 @@
|
||||||
"version": "0.0.0",
|
"version": "0.0.0",
|
||||||
"description": "vr experiments 3",
|
"description": "vr experiments 3",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"compile": "tsc",
|
|
||||||
"compile:watch": "tsc -w",
|
|
||||||
"rollup": "rollup -c",
|
"rollup": "rollup -c",
|
||||||
"rollup:watch": "rollup -c -w",
|
"rollup:watch": "rollup -c -w",
|
||||||
"prepare": "yarn run compile && yarn run rollup"
|
"prepare": "yarn run rollup"
|
||||||
},
|
},
|
||||||
"author": "Tony Garnock-Jones <tonyg@leastfixedpoint.com>",
|
"author": "Tony Garnock-Jones <tonyg@leastfixedpoint.com>",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
@ -15,7 +13,9 @@
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@rollup/plugin-node-resolve": "15.0",
|
"@rollup/plugin-node-resolve": "15.0",
|
||||||
|
"@rollup/plugin-typescript": "10.0",
|
||||||
"rollup": "3.8",
|
"rollup": "3.8",
|
||||||
|
"tslib": "2.4",
|
||||||
"typescript": "4.9"
|
"typescript": "4.9"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,11 +1,16 @@
|
||||||
|
// -*- javascript -*-
|
||||||
import resolve from '@rollup/plugin-node-resolve';
|
import resolve from '@rollup/plugin-node-resolve';
|
||||||
|
import typescript from '@rollup/plugin-typescript';
|
||||||
import path from 'path';
|
import path from 'path';
|
||||||
|
|
||||||
const babylon = '@babylonjs/core/Legacy/legacy';
|
const babylon = '@babylonjs/core/Legacy/legacy';
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
input: 'lib/index.js',
|
input: 'src/index.ts',
|
||||||
plugins: [resolve({ browser: true })],
|
plugins: [
|
||||||
|
resolve({ browser: true }),
|
||||||
|
typescript({ incremental: true }),
|
||||||
|
],
|
||||||
external: [
|
external: [
|
||||||
babylon,
|
babylon,
|
||||||
],
|
],
|
||||||
|
|
13
yarn.lock
13
yarn.lock
|
@ -19,6 +19,14 @@
|
||||||
is-module "^1.0.0"
|
is-module "^1.0.0"
|
||||||
resolve "^1.22.1"
|
resolve "^1.22.1"
|
||||||
|
|
||||||
|
"@rollup/plugin-typescript@10.0":
|
||||||
|
version "10.0.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/@rollup/plugin-typescript/-/plugin-typescript-10.0.1.tgz#270b515b116ea28320e6bb62451c4767d49072d6"
|
||||||
|
integrity sha512-wBykxRLlX7EzL8BmUqMqk5zpx2onnmRMSw/l9M1sVfkJvdwfxogZQVNUM9gVMJbjRLDR5H6U0OMOrlDGmIV45A==
|
||||||
|
dependencies:
|
||||||
|
"@rollup/pluginutils" "^5.0.1"
|
||||||
|
resolve "^1.22.1"
|
||||||
|
|
||||||
"@rollup/pluginutils@^5.0.1":
|
"@rollup/pluginutils@^5.0.1":
|
||||||
version "5.0.2"
|
version "5.0.2"
|
||||||
resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-5.0.2.tgz#012b8f53c71e4f6f9cb317e311df1404f56e7a33"
|
resolved "https://registry.yarnpkg.com/@rollup/pluginutils/-/pluginutils-5.0.2.tgz#012b8f53c71e4f6f9cb317e311df1404f56e7a33"
|
||||||
|
@ -120,6 +128,11 @@ supports-preserve-symlinks-flag@^1.0.0:
|
||||||
resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09"
|
resolved "https://registry.yarnpkg.com/supports-preserve-symlinks-flag/-/supports-preserve-symlinks-flag-1.0.0.tgz#6eda4bd344a3c94aea376d4cc31bc77311039e09"
|
||||||
integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==
|
integrity sha512-ot0WnXS9fgdkgIcePe6RHNk1WA8+muPa6cSjeR3V8K27q9BB1rTE3R1p7Hv0z1ZyAc8s6Vvv8DIyWf681MAt0w==
|
||||||
|
|
||||||
|
tslib@2.4:
|
||||||
|
version "2.4.1"
|
||||||
|
resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.4.1.tgz#0d0bfbaac2880b91e22df0768e55be9753a5b17e"
|
||||||
|
integrity sha512-tGyy4dAjRIEwI7BzsB0lynWgOpfqjUdq91XXAlIWD2OwKBH7oCl/GZG/HT4BOHrTlPMOASlMQ7veyTqpmRcrNA==
|
||||||
|
|
||||||
typescript@4.9:
|
typescript@4.9:
|
||||||
version "4.9.4"
|
version "4.9.4"
|
||||||
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.4.tgz#a2a3d2756c079abda241d75f149df9d561091e78"
|
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.9.4.tgz#a2a3d2756c079abda241d75f149df9d561091e78"
|
||||||
|
|
Loading…
Reference in New Issue