Open sahil-shubham opened 2 years ago
I would like to take up this issue.
Assigning this to you @chirag828049
I Tried doing this. However, I am facing some issues.
My plan was to use packages like node-sass or dart-sass to convert a sass string to css. However, those are server-side stuff and as such have dependencies like 'fs'.
To solve that, a quick google search suggested modifying the webpack config file by adding the folllowing code :
module.exports = { resolve: { fallback: { fs: false }, }, };
Well it solved some errors out of the 24 errors webpack was throwing.
I then tried the repo @OrkoHunter had suggested : https://github.com/medialize/sass.js/#sassjs It was in vanilla javascript and unmaintained since 2019. I gave it a try. Added it in the project. And the webpack failed to compile again. This time without showing any error.
If anyone has any idea how to make any of the above methods work, please help. I think that creating an api endpoint in a server will be the easiest way to go here. Also, it might help future instant app ideas.
For now, if there is any service providing api to convert sass to css, we can utilise that. However, I failed to find any such. Again, help here will be appreciated a lot.
Summary
An instant app to covert SASS to CSS.
Example search queries