Front End
Frameworks
Tailwind
Upgrade to Tailwind 2 — reference.
yarn add tailwindcss postcss@8 -D
// resources/assets/build/webpack.config.preset.js
postcssOptions: {
parser: config.enabled.optimize
? "postcss-safe-parser"
: undefined,
plugins: postcssPlugins,
sourceMap: false,
},
AlpineJS
Issues running it via NPM with Sage 9, so add from CDN.
// app/setup.php
add_action('wp_enqueue_scripts', function () {
wp_enqueue_script('alpine', '//unpkg.com/alpinejs', null, null, true);
}, 100);
<!-- add the inline style tag to the head to effectively use x-cloak -->
<style>
[x-cloak] {
display: none;
}
</style>