Comments (11)
I've created PR which should fix this as I've switched from MacOS to Windows during development recently and came into the same bug.
from elm-pages.
Thank you for your amazing response and dedication! :)
from elm-pages.
Hello @y0hy0h, thanks for helping to give context on this issue.
elm-pages
generates two different types of files. One that is used for the CLI runner, and another that is used by the Web runner.
I believe the issue you're seeing here is happening from the generated CLI code.
Could you try giving me the contents of the following generated file?
elm-stuff/elm-pages/Pages.elm
If you share the raw contents of that file, that will shed some light on what's going on and be a good first step. Thank you!
from elm-pages.
So that's where they get generated at! :D
I put the content of examples/docs/elm-stuff/elm-pages/Pages.elm
into a gist at https://gist.github.com/Y0hy0h/6edba330edbd0e405cf152a2f853ccfa.
from elm-pages.
No way, that's fantastic @vViktorPL thank you so much for pushing a fix! Just to confirm, did you test it out on WIndows and make sure it works smoothly with this change? I don't have access to a Windows machine so that would be helpful to know!
from elm-pages.
I've tested it in starter by modifing files temporarily in node_modules but maybe someone in the meantime can confirm this (@y0hy0h perhaps?) by switching dependency to the commit from that PR.
from elm-pages.
Yeah, @y0hy0h if you're willing to test it out, that would be awesome!
You can do so with these commands:
git clone [email protected]:vViktorPL/elm-pages.git
cd elm-pages
npm install && npm run build && npm install -g .
Then build your project with elm-pages develop
. Be sure not to use npm start
in your project as it will use the local version.
from elm-pages.
One more thing, it's on fix-windows-paths
branch so extra step after git clone is needed:
git checkout fix-windows-paths
.
from elm-pages.
I can confirm it works, I've tested this with my customized starter project and npm link
with fixed version :)
C:\Users\wtopo\Desktop\Projects\homepage>npm start
> [email protected] start C:\Users\wtopo\Desktop\Projects\homepage
> elm-pages develop
Running elm-pages...
Dependencies ready!
Success! Compiled 8 modules.
Main ---> C:\Users\wtopo\AppData\Local\Temp\2020215-14320-vrpq99.pcvs.js
Watching...
elm-pages DONE
� elm-pages develop on http://localhost:3000
webpack built feb5eb51dd1f8de3f6be in 2064ms
i 「wdm」: Compiled successfully.
i 「wdm」: Compiling...
webpack building...
Started compiling Elm..
webpack built 705a23bf12daa8dbbe19 in 915ms
i 「wdm」: Compiled successfully.
from elm-pages.
I can confirm that it works, too, both on the starter repo and the docs (up to the missing secrets that I don't provide).
from elm-pages.
Thank you both so much for the code, testing, and insights here! Really appreciate this 🙏 It's really nice to be able to clean this up for Windows users 👍
from elm-pages.
Related Issues (20)
- elm-pages run script/src/AddRoute.elm fails when run before first build HOT 4
- [SSCCE] ANSI escape codes in `onError` and `ErrorPage` error messages
- Provide a way to render static 404 pages using elm-pages HOT 2
- Replace StaticHttp examples in BackendTask HOT 1
- Cannot watch for fragment changes in URL
- Scroll is reset on back navigation HOT 1
- DeadCodeEliminateData errors cached in elm-stuff
- Feature request: `Pages.Script.writeFileBinary`/`BackendTask.File.rawBinary` HOT 2
- `elm-pages build` inserts `import FatalError` into unit test modules HOT 2
- Update .gitignore generator template for elm-pages-cli-mjs HOT 1
- Compilation error when using `elm-pages docs` HOT 9
- npx elm-pages run <script name> does not work on Windows HOT 1
- Vite Pre-transform error after upgrade HOT 9
- Initialization failed while loading node modules HOT 4
- Compatibility Keys match, but elm-pages says they don't when running script HOT 7
- Feature request: `BackendTask.race` HOT 1
- Feature request: `Script.stateful` HOT 1
- `Debug.todo` causes a `Script` to stop with no error message HOT 5
- INTERNAL ERROR when calling custom task. HOT 1
- BadBody: INTERNAL ERROR when input to Backend.Custom.run is mutated HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from elm-pages.