Pode
Pode copied to clipboard
Using CSS pre-processors with PowerShell Pode web framework
Describe the Change
I'd like to use SASS or LESS with Pode. At the moment, the documentation isn't super clear about how best to accomplish this. I would imagine that the ideal workflow would be to install LESS or SASS during a Docker container image build, and then execute the build tool somewhere inside the Dockerfile.
Curious if anyone else has attempted this yet.
It's been some time since I've used LESS, but I believe you're right that you could install the tool with npm/yarn in the container, and then execute it; something like:
FROM badgerati/pode:latest
WORKDIR /usr/src/app/
COPY . .
RUN yarn install less -g
RUN lessc ./path/style.less ./path/style.css
EXPOSE 8085
CMD [ "pwsh", "-c", "cd /usr/src/app; ./server.ps1" ]