Put flynt website in production #470
|
Hi there, Thanks! |
Replies: 3 comments 12 replies
|
Hi @comsup, I wrote a tutorial about deploying a Flynt theme with GitHub Actions: Depending on your build configuration, you might also exclude the Additionally, you could exclude the dotfiles, the composer-, webpack- and other build-files from the theme root directory. Please note: The standard build files do not include credentials, like database or server access. But if you customised the build process and added anything alike, be sure not to transfer files with credentials in it, unless necessary, because those might accidentally get exposed, depending on your production server configuration. That's why in the tutorial I'm excluding the |
|
Also is there a way to reduce the main.js size? the file size is 2.25mo, and I don't use a lots of js, is it the normal file size? |
|
Another (last!) issue is about linking the assets from .scss files for production. I have a component with an Assets folders and some .svf files on it. On the _style.scss of that component I refer to thoses svg like "content: url("../../Components/ComsUpNavigationTop/Assets/arrow-down.svg");" but when the run build is start the svg is copy to the dist folder but the link on my scss doesn't work anymore. Is there a good way to write link to svg or image in our scss file? |
Hi @comsup, I wrote a tutorial about deploying a Flynt theme with GitHub Actions:
https://css-tricks.com/continuous-deployments-for-wordpress-using-github-actions/
In that article, I'm primarily excluding the
node_modulesand.gitdirectories from the deployment.Depending on your build configuration, you might also exclude the
assetsfolder, as all assets should be revved and copied over into thedistfolder after thebuildstep. But yourassetsfolder might also include files that do not get copied over and would be missing.Additionally, you could exclude the dotfiles, the composer-, webpack- and other build-files from the theme root directory.
But excluding the
node_modules(and.git…