Closed conradwt closed 2 years ago
Hi @conradwt, the config example in the error message is wrong 🙈 Sorry you had to deal with that, I will fix it right away!
First thing, you need a colon between the input asset and the output filename. Change your config to the following:
config :dart_sass,
version: "1.49.9",
default: [
args: ~w(css/app.scss:../priv/static/assets/app.css),
cd: Path.expand("../assets", __DIR__)
]
...or you can simplify slightly by using directory names (this is my preference):
config :dart_sass,
version: "1.49.9",
default: [
args: ~w(css:../priv/static/assets),
cd: Path.expand("../assets", __DIR__)
]
Second thing, you won't need to include the asset filenames when you run the sass task because they are included in the config :) So you can run it like this:
$ mix sass default
The config difference is really subtle, and I think the first error message you received added more confusion because it came from the sass binary and not directly from this package, and then the second error message outright lied to you :)
When I run
mix sass default assets/css/app.scss priv/static/assets/app.css
, I'm seeing the following within the terminal:When I remove the default and use
mix sass assets/css/app.scss priv/static/assets/app.css
, I see the following within the terminal:Finally, I have defined the following profile within the
config/config.exs
file:Using the following dependencies:
Phoenix 1.6.6 Elixir 1.13.3 Erlang 24.2.2