runway-project / hangar-api

A competition organization and tournament orchestration API, built for Runway Project
MIT License
1 stars 0 forks source link

dev server #1

Open kauderk opened 7 months ago

kauderk commented 7 months ago

Hi, I want to run this but can't get it to run the server

I'm a windows user I tried node 18 & 21

"dev": "set NODE_ENV=development && node --experimental-specifier-resolution=node --enable-source-maps --loader ts-node/esm src/index.ts",
---
RangeError [ERR_UNKNOWN_MODULE_FORMAT]: Unknown module format: null for URL file:///C://hangar-api/src/pages/competitions/new.marko
MyraJia commented 7 months ago

Hi, right now the process for running this code in dev mode is a bit inconsistent, as I need to figure out a better way to get ts-node to work with Marko.

If you want to run this locally, my suggestion would be to instead do npm run build && node dist/index.js, as this will compile everything down to plain JS first. However, unfortunately, it won't auto-reload when you make changes to source code unless you combine it with a tool like Concurrently.

I'm hoping to update this project with some better documentation and a more polished onboard process soon, but this project has been on the back-burner recently.

Alternatively, if you're just interested in using the code to run a KSP BDA competition rather than running your own instance, feel free to use https://hangar-api.space/ instead. Anyone with a Discord account can use this site to run or join competitions.