-
Notifications
You must be signed in to change notification settings - Fork 147
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integrate elm-css #137
Integrate elm-css #137
Conversation
It seems that the |
template/elm-package.json
Outdated
@@ -10,7 +10,9 @@ | |||
"exposed-modules": [], | |||
"dependencies": { | |||
"elm-lang/core": "5.0.0 <= v < 6.0.0", | |||
"elm-lang/html": "2.0.0 <= v < 3.0.0" | |||
"elm-lang/html": "2.0.0 <= v < 3.0.0", | |||
"rtfeldman/elm-css": "8.2.0 <= v < 9.0.0", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm afraid elm-css
is supposed to be purely optional, the template should be kept in its initial state.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sure, no problem 👍
template/src/index.js
Outdated
@@ -1,4 +1,5 @@ | |||
import './main.css' | |||
import './Stylesheets.elm' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This kind of stuff should be documented in User Guide.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, sounds reasonable. Should I also delete the file Stylesheets.elm
and instead provide an example on how to create this file in the user guide?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@MazeChaZer yes, that sound good 👍
Good job, the progress so far looks promising. Please ping me if you're having troubles with |
9f7a797
to
6fcfef1
Compare
Update on the current status:
From my side this pull request would be ready to be merged ⭐ |
@MazeChaZer great job! Thank you for this PR 👍 This code will go into |
6fcfef1
to
7e12e88
Compare
@halfzebra Great, just ping me if you need a rebase :) |
7e12e88
to
57ed836
Compare
57ed836
to
30d8565
Compare
30d8565
to
9979b1e
Compare
Just rebased this PR on top of the current master. I included the |
@MazeChaZer Sorry, it took us so long to get back to this PR. #135 was taking way too much time. We've been discussing @rtfeldman pointed out that style-elements might become a successor of @eeue56 have recommended on having a designated chapter in User Guide instead of introducing some special handling of an I feel like the community consensus at the moment is leaning towards the idea of not including any I know you have been working hard on that and that you did a very good job. We'd love to keep the docs and have the guide about I'm sorry we couldn't accept the PR in it's current state, but I'm also pretty sure that, the documentation you've made, can be adjusted to cover |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please remove elm-css specific webpack configuration
I am excited about this one. Nice work! 😄 |
@RyanCCollins thanks for the feedback! Initially, we intended to close this PR, because If there's more interest in having a more friendly Could you please elaborate, why are you interested in Have you tried style-elements? |
Hey @halfzebra, I just re-read your comment and considering that Richard is saying that elm-styled is the future, I'd be interested in it over elm-css. I like the idea of having some kind of typed css api either way. |
elm-styled is not what Richard thinks is the way forward. |
@RyanCCollins the main advantage of style-elements is that it does not require additional setup. Richard's opinion was that there is no recommended way of doing CSS in Elm. @MazeChaZer I'm going to refine this PR and add sections to the User Guide covering the setup for |
@eeue56 my bad, I have been referring to the wrong package 😦 Thanks for pointing that out! |
@halfzebra Thanks, sorry for not responding earlier. We probably won't be using Elm in production in the long run, so this issue wasn't as important to me as it was when I started this pull request. I understand your decision to keep |
|
||
```sh | ||
elm-app package install rtfeldman/elm-css | ||
elm-app package install elm-css-helpers |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This command doesn't work, it says:
Uh oh, argument "elm-css-helpers" is not a valid PACKAGE
There should be a slash separating the user and project name (user/project)
So it should be:
elm-app package install rtfeldman/elm-css-helpers
@halfzebra Thanks for taking care of this :) |
Tracked in #134
I tried to implement this as we discussed.
The stylesheet module is called
Stylesheets
, notStylesheet
, because I coundn't find a way to make elm-css-webpack-loader load a different module. In all the elm-css examples I saw, the plural version of the name was used, so this might not be so bad.I included the
noParse
workaround you proposed.There is an example
Stylesheets
module which is included inindex.js
and elm-css dependencies are added to elm-package.json.