[REQUEST] Fresh Integration: Allow jsonc type to Deno config file
btd1337 opened this issue · 1 comments
btd1337 commented
Problem
If you are importing a fresh project into Danet that has Deno config file in jsonc
, then fresh integration won't work.
fresh_app
|_ deno.jsonc
Error
$ deno task launch-server
Task launch-server deno run --allow-net --allow-read --allow-run --allow-write --unstable --allow-env run.ts
The manifest has been generated for 7 routes and 0 islands.
error: Uncaught (in promise) TypeError: Module not found "file:///danet_app/src/fresh_app/deno.json".
at file:///danet_app/src/fresh_app/fresh.gen.ts:5:20
const manifest = (await import(url + './fresh.gen.ts')).default;
^
at async Function.enableFreshOnRoot (https://deno.land/x/danet_fresh@0.0.1/mod.ts:43:21)
at async bootstrap (file:///danet_app/src/bootstrap.ts:14:3)
at async file:///danet_app/run.ts:3:21
Solution
Allow to pass Deno config file type in FreshModule.enableFreshOnRoot
function.
Enum options:
json
(default),jsonc
enum DenoConfigFileType {
JSON = 'json',
JSONC = 'jsonc'
}
Sorikairox commented
Hey @btd1337, thanks a lot for all your issue/enhancement tickets for Fresh !
Sadly, I probably plan to drop supporting fresh for V2...