FinishedHim Posted September 5, 2019 Posted September 5, 2019 (edited) Hi, I searched for this problem a while but it seems like I´m the only one with this question. I´m using Webstorm as IDE and Typescript as language on Server and Client-Side. On Client side I have the probblem that the Client doesnt find my modules because of the wrong require-paths. If i change the path to the path rage needs to have, my IDE throws errors on compilation. For example my gamemode is named "script" and inside it I have the files "index.js" and "test.js". For rage I have to add the root folder to include the "test.js" from "index.js" with something like that: "require('./script/test')... If i do so my IDE cries because it wants the require like that: "require('./test')" . I saw some Gamemodes that use just the relative path without the rootfolder prefix. How is this possible, this would be the perfect solution. Is it possible to ignore the "/script" part in requires over the tsconfig.json file? I hope you can help me Edit: I´m searching for a prettier way than just add a ts-ignore statement, if it exists Edited September 5, 2019 by FinishedHim
Captien Posted September 5, 2019 Posted September 5, 2019 You can check some Typescript boilerplates on github
FinishedHim Posted September 5, 2019 Author Posted September 5, 2019 Am I getting that right that the target is not to have multiple gamemodes in the client-packages folder? So i just can break my folder structure one level down and i have everything i want?
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now