choonkeat / elm-serverless-edge

Elm on Cloudflare Workers & KV store
https://elm.choonkeat.workers.dev/
3 stars 0 forks source link

App does not build or run, files are missing #1

Open sdaves opened 2 years ago

sdaves commented 2 years ago

I think some files are missing, I get this error when building:

[user@user-32492tu elm-serverless-edge]$ make
find: ‘extensions’: No such file or directory
find: ‘extensions’: No such file or directory
touch index.js
npm init --yes
Wrote to /home/user/Documents/elm-serverless-edge/package.json:

{
  "name": "elm-serverless-edge",
  "version": "1.0.0",
  "description": "_NOTE: this repo is an early iteration of [elm-webapp](https://github.com/choonkeat/elm-webapp). ideally we re-introduce a cloudflare workers runtime to [elm-webapp](https://github.com/choonkeat/elm-webapp) instead_",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "repository": {
    "type": "git",
    "url": "git+https://github.com/choonkeat/elm-serverless-edge.git"
  },
  "keywords": [],
  "author": "",
  "license": "ISC",
  "bugs": {
    "url": "https://github.com/choonkeat/elm-serverless-edge/issues"
  },
  "homepage": "https://github.com/choonkeat/elm-serverless-edge#readme"
}

which elm || npm add "elm@~0.19"
/usr/bin/elm
npm add \
    "full-url" \
    "node-static" \
    "w3c-xmlhttprequest" \
    "webpack" \
    "webpack-cli" \
    "form-data" \
    "nodemailer"

added 133 packages, and audited 134 packages in 7s

17 packages are looking for funding
  run `npm fund` for details

3 moderate severity vulnerabilities

To address issues that do not require attention, run:
  npm audit fix

Some issues need review, and may require choosing
a different dependency.

Run `npm audit` for details.
elm make --output build/Client.js src/Client.elm
Dependencies ready!         
-- MISSING SOURCE DIRECTORY ------------------------------------------- elm.json

I need a valid elm.json file, but the "source-directories" field lists the
following directory:

    extensions

I cannot find it though. Is it missing? Is there a typo?

make: *** [Makefile:62: build/Client.js] Error 1
[user@user-32492tu elm-serverless-edge]$ make preview
find: ‘extensions’: No such file or directory
find: ‘extensions’: No such file or directory
make: *** No rule to make target 'preview'.  Stop.
[user@user-32492tu elm-serverless-edge]$
choonkeat commented 2 years ago

Indeed! Sorry about that. I don't actually have this on my machine anymore too :-\ so the only option would be to add Cloudflare wrangler support to https://github.com/choonkeat/elm-webapp directly or by a PR style illustration