-
-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Labels
Description
Description:
Using TypeScript path aliases like @/enum/tags works in VSCode, but sand build fails:
Error: Cannot find module '@/enum/tags'
Steps to Reproduce:
- tsconfig.json:
{
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@/*": ["src/*"]
}
}
}- Code using the alias:
// src/enum/tags.ts
import { Tag } from 'sandstone';
export const ENIMY = Tag('entity_types', 'enimy', [
"#skeletons",
"minecraft:zombie",
"minecraft:piglin",
"spider",
"enderman",
"shulker",
"drowned",
"husk",
"stray",
]);
// some other file
import { ENIMY } from '@/enum/tags';- Run build:
pnpm buildExpected:
Sandstone should resolve the alias like TypeScript does.
Environment:
- Sandstone CLI: 0.5.4
- OS: Windows