#Importing constant from .ts file compile error

2 messages · Page 1 of 1 (latest)

teal beacon
#

Is your server file extension js or ts? I find it odd you call it server.js, but the error is trying to use server.ts. Could just be a red herring and how TS does its thing.

hidden quarry
#

baseUrl is "./src". based on this: https://www.typescriptlang.org/tsconfig#baseUrl
shouldn't your import be:

import {MOVE_SPEED} from "playerConfig";

if not, I suspect it's still an issue with that relative path. in what directory is server.ts and in what directory is playerConfig.ts?