You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've tried to set up a basic typescript project but failed.
I've just called 'npm init', 'tsc --init', 'npm install cross-shader --save', and added 'test.ts' with the code from 'readme.md'.
Looks like 'tsc' does not see anything from 'd.ts' file.
Part of the 'tsc' output:
src/index.ts:16:14 - error TS7031: Binding element 'compile' implicitly has an 'any' type.
16 xsdr.then(({ compile, ShaderFormat, ShaderStage }) => {
~~~~~~~
It creates '.js' file but when I try to run it, it fails. Parts of the output:
TypeError: cross_shader_1.default.then is not a function
at Object.<anonymous> (/Users/romamik/work/tmp-shader-compiler/src/index.js:18:24)
at Module._compile (internal/modules/cjs/loader.js:1085:14)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:1114:10)
at Module.load (internal/modules/cjs/loader.js:950:32)
at Function.Module._load (internal/modules/cjs/loader.js:790:12)
at Function.executeUserEntryPoint [as runMain] (internal/modules/run_main.js:76:12)
at internal/main/run_main_module.js:17:47
Then I decided to manually edit generated '.js' file
and changed cross_shader_1.default.then to cross_shader_1.default.default.then. And after that everything worked. But that is just strange.
The text was updated successfully, but these errors were encountered:
I've tried to set up a basic typescript project but failed.
I've just called 'npm init', 'tsc --init', 'npm install cross-shader --save', and added 'test.ts' with the code from 'readme.md'.
Looks like 'tsc' does not see anything from 'd.ts' file.
Part of the 'tsc' output:
It creates '.js' file but when I try to run it, it fails. Parts of the output:
Then I decided to manually edit generated '.js' file
and changed
cross_shader_1.default.then
tocross_shader_1.default.default.then
. And after that everything worked. But that is just strange.The text was updated successfully, but these errors were encountered: