Globally Including JavaScript

  1. Create a new file in resources/js
  2. Import the file in resources/js/app.js
  3. Run bun run dev
  4. Include the file in your Blade tile @vite('resources/js/custom.js')

The Working JavaScript

document.querySelector('meta[name="theme-color"]').setAttribute('content', '#123456');

javascript css