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
fs, path or other node-specific modules might be accidentally imported, and browser version would have to mock them. There is already a VirtualFileSystem that should be the only interface to file system.
__dirname shouldn't be used outside of *.build.ts and *.spec.ts files. Compiler doesn't have to know where its sources are.
To do
Create separate package with compiler internals (@tact-lang/core?)
src/vfs/createNodeFileSystem.ts should be left in @tact-lang/compiler.
Ensure only posix (/) paths are passed to internals package.
Remove @types/node dependency from internals package.
Ban __dirname with eslint.
The text was updated successfully, but these errors were encountered:
Issues
fs
,path
or other node-specific modules might be accidentally imported, and browser version would have to mock them. There is already a VirtualFileSystem that should be the only interface to file system.__dirname
shouldn't be used outside of*.build.ts
and*.spec.ts
files. Compiler doesn't have to know where its sources are.To do
@tact-lang/core
?)src/vfs/createNodeFileSystem.ts
should be left in@tact-lang/compiler
./
) paths are passed to internals package.@types/node
dependency from internals package.__dirname
with eslint.The text was updated successfully, but these errors were encountered: