actions-hugo icon indicating copy to clipboard operation
actions-hugo copied to clipboard

Integrate Dart Sass

Open faraixyz opened this issue 4 years ago • 6 comments

Is your feature request related to a problem? Please describe.

From 0.80, Hugo has dart sass support, but it needs dart sass embedded.

Describe the solution you'd like

Including dart sass embedded in the action, but it needs to be done carefully because the different versions have their compatibility issues.

Describe alternatives you've considered

Doing it in the workflow definition.

Additional context

Add any other context or screenshots about the feature request here.

faraixyz avatar Mar 04 '21 18:03 faraixyz

Thank you for your suggestion! ʕ◔ϖ◔ʔ

When I saw the Hugo v0.80.0 first, I thought about this option, me too. According to the documentation, Hugo seems to have a plan to bind the Embedded Dart Sass as the same as LibSass (Hugo extended). I expect that the improvement will be done at bep/godartsass.

The transpiler to use, valid values are libsass (default) and dartsass. Note that the Embedded Dart Sass project is still in beta (beta 5 at the time of writing). The release is scheduled for Q1 2021. We will try to improve the installation process by then, but if you want to use Hugo with Dart Sass you need to download a release binary from Embedded Dart Sass (Hugo after 0.81.0 requires beta 6 or newer) and make sure it’s in your PC’s $PATH (or %PATH% on Windows).

https://gohugo.io/hugo-pipes/scss-sass/#options

The plan looks worth the wait.

peaceiris avatar Mar 04 '21 22:03 peaceiris

That's cool. Thanks for making this project.

faraixyz avatar Mar 04 '21 22:03 faraixyz

I also have opened a related issue in gohugoio/hugo: Binding Embedded Dart Sass into Hugo · Issue #8299 · gohugoio/hugo

peaceiris avatar Mar 04 '21 22:03 peaceiris

We cannot (I'm probably sure about that) embed this into Hugo's binary (the embedded files in Go 1.16 is not executable).

https://github.com/gohugoio/hugo/issues/8299#issuecomment-791245030

We found that the installation of the Embedded Dart Sass should be handled by this action. I will work on this! ʕ◔ϖ◔ʔ

peaceiris avatar Mar 05 '21 08:03 peaceiris