aforemny / elm-mdc

Elm port of the Material Components for the Web CSS/JS library
https://aforemny.github.io/elm-mdc
Apache License 2.0
354 stars 43 forks source link

Demo not working correctly due to wrong paths in page.html #270

Closed eddex closed 4 years ago

eddex commented 4 years ago

I've noticed that the demo page doesn't work as it should.

Steps to reproduce:

Chrome (Brave): image

Firefox: image

berenddeboer commented 4 years ago

You will need to go to to /build/index.html I believe. So I run make build-demo and then load index.html in the build page: http://localhost:8000/build/index.html, and that seems to work fine.

I'm not very familiar with elm reactor, why would you use that on the demo page itself?

aforemny commented 4 years ago

Hi @eddex, as @berenddeboer stated our demo does not work with elm-reactor unfortunately.

The reason for that is that elm-reactor is strictly a tool for beginning Elm development. As soon as you have a more advanced application in the sense that you might require interaction with JavaScript (ports) or load external assets such as JavaScript or CSS files, you should eject from using elm-reactor. You can read up on how to do that here.

Since this library requires external assets to function (elm-mdc.js, material-components-web.css), we unfortunately cannot support elm-reactor.