In this case, I forgot to pass -c tsconfig.json to add DOM to the libs. I'm assuming this should be instead outputting the compile errors.
PS C:\Users\mark\Documents\PROJECTS\deno-test> deno --version
deno 1.0.0
v8 8.4.300
typescript 3.9.2
PS C:\Users\mark\Documents\PROJECTS\deno-test> deno bundle ./src/index.ts
Bundling file:///C:/Users/mark/Documents/PROJECTS/deno-test/src/index.ts
error: Uncaught AssertionError: Assertion failed.
at Object.assert ($deno$/util.ts:33:11)
at compile ($deno$/compiler.ts:1355:5)
at async tsCompilerOnMessage ($deno$/compiler.ts:1548:22)
at async workerMessageRecvCallback ($deno$/runtime_worker.ts:74:9)
@Ragzouken thanks for the issue, I just discovered it myself and it will be fixed in #5029
Yeah, that seemed to fix it, but now i'm getting:
error: missing field `bundleOutput` at line 1 column 69284
That's from building from 9d63772f (the commit which merges #5029 ) and from the master branch. TypeScript source at v3.9.2 if that helps.
@paskausks thanks for a catch, can you provide full command you run?
@bartlomieju .\target\release\deno.exe bundle -c tsconfig.json index.ts index.js
The tsconfig is:
{
"compilerOptions": {
"lib": [ "DOM", "ES6", "DOM.Iterable", "ScriptHost"],
"strict": true,
"esModuleInterop": true
},
"exclude": [
"public"
]
}
@bartlomieju found the issue which caused this (the same which caused the AssertionError initially) - an import from my emotion reexport.
from index.ts:
import { css } from "./emotion.js";
and emotion.js
// @deno-types=https://github.com/emotion-js/emotion/blob/v10.0.6/packages/emotion/types/index.d.ts
export * from 'https://unpkg.com/[email protected]/dist/emotion.esm.js?module';
For comparison - I have preact and htm re-exports and those work fine.
@paskausks thanks for repro, I'll look into it.
I'm getting this same error, but haven't created a reproduction yet
Most helpful comment
@Ragzouken thanks for the issue, I just discovered it myself and it will be fixed in #5029