Remove all client-side JS from your Nuxt 3 app

Overview

Nuxt Zero JS

npm version npm downloads Github Actions Codecov

Remove all client-side JS from your Nuxt 3 app

Features

⚠️ nuxt-zero-js is under active development. ⚠️

  • Completely removes preload/prefetch hints for JS bundle
  • 🚀 Removes <script> tag for payload and JS bundle
  • 🙏 Leaves your own head tags intact

Follow this issue for more information, and do comment if you'd like to see this feature in Nuxt itself.

Usage

export default defineNuxtConfig({
  modules: ['nuxt-zero-js'],
  //
  // By default the module is disabled in development for better
  // DX but you can force it to be enabled if you would like.
  //
  // zeroJs: {
  //   disabled: false,
  // },

That's it!

💻 Development

  • Clone this repository
  • Enable Corepack using corepack enable (use npm i -g corepack for Node.js < 16.10)
  • Install dependencies using pnpm install
  • Stub module with pnpm dev:prepare
  • Run pnpm dev to start playground in development mode

License

Made with ❤️

Published under the MIT License.

Comments
  • chore(deps): update node.js to v18.13.0

    chore(deps): update node.js to v18.13.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | |---|---|---|---| | node | volta | minor | 18.12.1 -> 18.13.0 |


    Release Notes

    nodejs/node

    v18.13.0: 2023-01-05, Version 18.13.0 'Hydrogen' (LTS), @​danielleadams

    Compare Source

    Notable changes
    Add support for externally shared js builtins

    By default Node.js is built so that all dependencies are bundled into the Node.js binary itself. Some Node.js distributions prefer to manage dependencies externally. There are existing build options that allow dependencies with native code to be externalized. This commit adds additional options so that dependencies with JavaScript code (including WASM) can also be externalized. This addition does not affect binaries shipped by the Node.js project but will allow other distributions to externalize additional dependencies when needed.

    Contributed by Michael Dawson in #​44376

    Introduce File

    The File class is part of the FileAPI. It can be used anywhere a Blob can, for example in URL.createObjectURL and FormData. It contains two properties that Blobs do not have: lastModified, the last time the file was modified in ms, and name, the name of the file.

    Contributed by Khafra in #​45139

    Support function mocking on Node.js test runner

    The node:test module supports mocking during testing via a top-level mock object.

    test('spies on an object method', (t) => {
      const number = {
        value: 5,
        add(a) {
          return this.value + a;
        },
      };
      t.mock.method(number, 'add');
    
      assert.strictEqual(number.add(3), 8);
      assert.strictEqual(number.add.mock.calls.length, 1);
    });
    

    Contributed by Colin Ihrig in #​45326

    Other notable changes
    • build:
      • disable v8 snapshot compression by default (Joyee Cheung) #​45716
    • crypto:
      • update root certificates (Luigi Pinca) #​45490
    • deps:
      • update ICU to 72.1 (Michaël Zasso) #​45068
    • doc:
      • add doc-only deprecation for headers/trailers setters (Rich Trott) #​45697
      • add Rafael to the tsc (Michael Dawson) #​45691
      • deprecate use of invalid ports in url.parse (Antoine du Hamel) #​45576
      • add lukekarrys to collaborators (Luke Karrys) #​45180
      • add anonrig to collaborators (Yagiz Nizipli) #​45002
      • deprecate url.parse() (Rich Trott) #​44919
    • lib:
      • drop fetch experimental warning (Matteo Collina) #​45287
    • net:
      • (SEMVER-MINOR) add autoSelectFamily and autoSelectFamilyAttemptTimeout options (Paolo Insogna) #​44731
    • src:
      • (SEMVER-MINOR) add uvwasi version (Jithil P Ponnan) #​45639
      • (SEMVER-MINOR) add initial shadow realm support (Chengzhong Wu) #​42869
    • test_runner:
      • (SEMVER-MINOR) add t.after() hook (Colin Ihrig) #​45792
      • (SEMVER-MINOR) don't use a symbol for runHook() (Colin Ihrig) #​45792
    • tls:
      • (SEMVER-MINOR) add "ca" property to certificate object (Ben Noordhuis) #​44935
      • remove trustcor root ca certificates (Ben Noordhuis) #​45776
    • tools:
      • update certdata.txt (Luigi Pinca) #​45490
    • util:
      • add fast path for utf8 encoding (Yagiz Nizipli) #​45412
      • improve textdecoder decode performance (Yagiz Nizipli) #​45294
      • (SEMVER-MINOR) add MIME utilities (#​21128) (Bradley Farias) #​21128
    Commits

    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update pnpm to v7.22.0

    chore(deps): update pnpm to v7.22.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 7.21.0 -> 7.22.0 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v7.22.0

    Compare Source

    Minor Changes

    • The pnpm list and pnpm why commands will now look through transitive dependencies of workspace: packages. A new --only-projects flag is available to only print workspace: packages.
    • pnpm exec and pnpm run command support --resume-from option. When used, the command will executed from given package #​4690.
    • Expose the npm_command environment variable to lifecycle hooks & scripts.

    Patch Changes

    • Fix a situation where pnpm list and pnpm why may not respect the --depth argument.
    • Report to the console when a git-hosted dependency is built #​5847.
    • Throw an accurate error message when trying to install a package that has no versions, or all of its versions are unpublished #​5849.
    • replace dependency is-ci by ci-info (is-ci is just a simple wrapper around ci-info).
    • Only run prepublish scripts of git-hosted dependencies, if the dependency doesn't have a main file. In this case we can assume that the dependencies has to be built.
    • Print more contextual information when a git-hosted package fails to be prepared for installation #​5847.

    Our Gold Sponsors

    Our Silver Sponsors


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update devdependency husky to v8.0.3

    chore(deps): update devdependency husky to v8.0.3

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | husky (source) | 8.0.2 -> 8.0.3 | age | adoption | passing | confidence |


    Release Notes

    typicode/husky

    v8.0.3

    Compare Source

    • fix: add git not installed message #​1208

    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update devdependency eslint-config-prettier to v8.6.0

    chore(deps): update devdependency eslint-config-prettier to v8.6.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | eslint-config-prettier | 8.5.0 -> 8.6.0 | age | adoption | passing | confidence |


    Release Notes

    prettier/eslint-config-prettier

    v8.6.0

    Compare Source

    • Added: [vue/multiline-ternary]. Thanks to @​xcatliu!

    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update test packages to v0.26.3

    chore(deps): update test packages to v0.26.3

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | @vitest/coverage-c8 | 0.26.2 -> 0.26.3 | age | adoption | passing | confidence | | vitest | 0.26.2 -> 0.26.3 | age | adoption | passing | confidence |


    Release Notes

    vitest-dev/vitest

    v0.26.3

    Compare Source

       🚀 Features
       🐞 Bug Fixes
        View changes on GitHub

    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about these updates again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update devdependency eslint to v8.31.0

    chore(deps): update devdependency eslint to v8.31.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | eslint (source) | 8.30.0 -> 8.31.0 | age | adoption | passing | confidence |


    Release Notes

    eslint/eslint

    v8.31.0

    Compare Source

    Features

    • 52c7c73 feat: check assignment patterns in no-underscore-dangle (#​16693) (Milos Djermanovic)
    • b401cde feat: add options to check destructuring in no-underscore-dangle (#​16006) (Morten Kaltoft)
    • 30d0daf feat: group properties with values in parentheses in key-spacing (#​16677) (Francesco Trotta)

    Bug Fixes

    • 35439f1 fix: correct syntax error in prefer-arrow-callback autofix (#​16722) (Francesco Trotta)
    • 87b2470 fix: new instance of FlatESLint should load latest config file version (#​16608) (Milos Djermanovic)

    Documentation

    Chores


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update pnpm to v7.21.0

    chore(deps): update pnpm to v7.21.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 7.20.0 -> 7.21.0 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v7.21.0

    Compare Source

    Minor Changes

    • The pnpm dlx command supports the --shell-mode (or -c) option. When used, the script is executed by a shell #​5679.

    Patch Changes

    • The config command should work with the --location=global CLI option #​5841.
    • Only the pnpm add --global <pkg> command should fail if there is no global pnpm bin directory in the system PATH #​5841.

    Our Gold Sponsors

    Our Silver Sponsors


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update devdependency release-it to v15.6.0

    chore(deps): update devdependency release-it to v15.6.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | release-it | 15.5.1 -> 15.6.0 | age | adoption | passing | confidence |


    Release Notes

    release-it/release-it

    v15.6.0

    Compare Source


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update devdependency @types/node to v18.11.18

    chore(deps): update devdependency @types/node to v18.11.18

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | @types/node (source) | 18.11.17 -> 18.11.18 | age | adoption | passing | confidence |


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update pnpm to v7.20.0

    chore(deps): update pnpm to v7.20.0

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | pnpm (source) | 7.19.0 -> 7.20.0 | age | adoption | passing | confidence |


    Release Notes

    pnpm/pnpm

    v7.20.0

    Compare Source

    Minor Changes

    • pnpm gets its own implementation of the following commands:

      • pnpm config get
      • pnpm config set
      • pnpm config delete
      • pnpm config list

      In previous versions these commands were passing through to npm CLI.

      PR: #​5829 Related issue: #​5621

    • Add show alias to pnpm view #​5835.

    • pnpm reads settings from its own global configuration file at $XDG_CONFIG_HOME/pnpm/rc #​5829.

    • Add the 'description'-field to the licenses output #​5836.

    Patch Changes

    • pnpm rebuild should not fail if node_modules was created by pnpm version 7.18 or older #​5815.
    • pnpm env should print help.
    • Run the prepublish scripts of packages installed from Git #​5826.
    • pnpm rebuild should print a better error message when a hoisted dependency is not found #​5815.

    Our Gold Sponsors

    Our Silver Sponsors


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): update devdependency @types/node to v18.11.17

    chore(deps): update devdependency @types/node to v18.11.17

    Mend Renovate

    This PR contains the following updates:

    | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | @types/node (source) | 18.11.15 -> 18.11.17 | age | adoption | passing | confidence |


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    dependencies chore 
    opened by renovate[bot] 1
  • chore(deps): pin dependencies

    chore(deps): pin dependencies

    Mend Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---|---|---| | @​nuxt/module-builder | devDependencies | pin | ^0.1.7 -> 0.1.7 | age | adoption | passing | confidence | | @nuxt/test-utils | devDependencies | patch | 3.0.0-rc.11 -> 3.0.0 | age | adoption | passing | confidence | | nuxt | devDependencies | pin | ^3.0.0-rc.11 -> 3.0.0 | age | adoption | passing | confidence |

    Add the preset :preserveSemverRanges to your config if you don't want to pin your dependencies.


    Release Notes

    nuxt/framework

    v3.0.0: Nuxt 3.0 stable

    Compare Source

    Official Release Announcenment

    💬 Release Discussion

    📝 Changelog

    Check out v3.0.0-rc.14 for other recent changes.

    🩹 Fixes
    • nuxt: Removed auto imports (#​9045)
    • schema: Initialise runtimeConfig.public with empty object (#​9050)
    • cli: Upgrade with latest tag (#​9060)
    • nuxt: Allow union type arguments for useAsyncData (#​9061)
    📖 Documentation
    • New website design (#​9007)
    • Update website theme version (819deb89)
    • Minor style improvements (9ab069b2)
    • Update website-theme (780b17b1)
    • Add warning about definePageMeta issues with transitions and NuxtLoadingIndicator (#​9055)
    • Add missing agencies (#​9059)
    🏡 Chore
    ❤️ Contributors

    v3.0.0-rc.14

    Compare Source

    Note This is the last release candidate for Nuxt v3! Are you ready? 👀

    👉 Release Discussion

    Changelog

    compare changes

    ⚠️ Breaking Changes
    • cli: Setup nuxt globally with nuxt test (#​4578)
    • nuxt: Only add $f fetch prefix to auto-keys (#​8852)
    • test-utils: Use vitest/node subpath export (#​8815)
    • nuxt: Remove initialCache option (#​8885)
    • nuxt: Enable payload extraction only for nuxi generate (#​9018)
    • nuxt: Include request url and params in useFetch key (#​6632)
    • nuxt: Fix typo for NuxtRenderHTMLContext.bodyPrepend (#​8712) (#​8704)
    • nuxt: Remove support for 404.vue shorthand (#​8809)
    • kit: Remove support for module container (#​9010)
    • nuxt: Move head option support into defineNuxtComponent (#​8901)
    • Remove deprecated api (#​9029) - Remove PrivateRuntimeConfig interface support - Remove autoImports option - Remove autoImports:extend hook support - Remove deprecated addAutoImport and addAutoImport utilities (use addImports and addImportsDir) - Remove defer option for useAsyncData - Remove support for installModule(nuxt, nuxtModule) - Remove support for module defenition as function - Remove support for name in module definition (use meta.name) - Remove deprecated throwError (use showError) - Remove deprecated useActiveRoute (use useRoute) - Remove deprecated NuxtConfig and defineNuxtConfig imports from nuxt (import from nuxt/config) - Remove deprecated <Script> component (use useHead) - Remove deprecated RouterConfigOptions interface (use RouterConfigSerializable) - Remove deprecated fileName for template options (use filename) - Remove deprecated <NuxtNestedPage> and <NuxtChild> components - Remove deprecated buildModules config - Remove deprecated privateRuntimeConfig and publicRuntimeConfig options - Remove deprecated imports.presets[].name (use presets.imports instead)
    🚀 Enhancements
    • nuxt: Add isExternal to <NuxtLink> slot props (#​8800)
    • nuxt: Auto-import utils/ directory (#​8817)
    • cli: Wrap and normalize all console outputs (#​8846)
    • nuxt: Allow customizing root id and tag (#​8883)
    • nuxt: Add onBeforeRouteLeave and onBeforeRouteUpdate composables (#​8889)
    • cli: ⚠️ Setup nuxt globally with nuxt test (#​4578)
    • cli: Auto-generate .npmrc and setting for pnpm (#​7407)
    • nuxt, schema: Migrate to @​vueuse/head v1 (#​8975)
    🩹 Fixes
    • nuxt: Check if global transitions are activated for scroll behavior (#​8700)
    • nuxt: Allow cookies to be set to null to unset them (#​8769)
    • nuxt: Add catchall paths to prerender list (#​8782)
    • schema: Add declarations to ignore list (#​8787)
    • ssr: Ensure useRequestHeaders are case-insensitive (#​8805)
    • nuxt: Do not render page if we are throwing error (#​8821)
    • nuxt: Swallow issues with query selectors (#​8843)
    • nuxt: ⚠️ Only add $f fetch prefix to auto-keys (#​8852)
    • test-utils: Detect project root using nuxt.config with .mjs and .cjs extensions (#​8855)
    • cli: Exclude dist from type checking (#​8848)
    • test-utils: ⚠️ Use vitest/node subpath export (#​8815)
    • nuxt: Detect non-functional imports within page meta (#​8881)
    • nuxt: Preserve render errors (#​8884)
    • nuxt: ⚠️ Remove initialCache option (#​8885)
    • nuxt: Use app.baseURL when fetching error page on server (#​8888)
    • nuxt: Avoid passing attrs to default slot for <ClientOnly> component (#​8921)
    • vite: Add extend layers to fs.allow (#​9006)
    • nuxt: Include layers in esbuild transform (#​9014)
    • kit: Add external module to transpile (#​8963)
    • nuxt: ⚠️ Enable payload extraction only for nuxi generate (#​9018)
    • nuxt: ⚠️ Include request url and params in useFetch key (#​6632)
    • nuxt: Improve hmr for pages macros (#​8940)
    💅 Refactors
    • nuxt: ⚠️ Fix typo for NuxtRenderHTMLContext.bodyPrepend (#​8712)
    • nuxt: ⚠️ Fix typo for NuxtRenderHTMLContext.bodyPrepend (#​8704)
    • nuxt: ⚠️ Remove support for 404.vue shorthand (#​8809)
    • nuxt: Explicitly import app in nuxt-root (#​8729)
    • kit: ⚠️ Remove support for module container (#​9010)
    • Update unjs dependencies to stable v1 (#​9011)
    • nuxt: ⚠️ Move head option support into defineNuxtComponent (#​8901)
    • ⚠️ Remove deprecated api (#​9029)
    📖 Documentation
    • Update 2.nuxt-page.md (#​8761)
    • Update roadmap for november (#​8766)
    • Use update import for defineLazyEventHandler (#​8767)
    • Remove stability-edge (507f444c)
    • deployment: Remove usage of custom icons (8e4068b7)
    • Improve examples content (1582f8ec)
    • api: Add useRequestHeaders composable example (#​8833)
    • Add entry for extendPages (#​8860)
    • api: Add refreshNuxtData util examples (#​8845)
    • Get event before running async function (#​8861)
    • api: Add useHydration composable (#​8768)
    • Add query option with example for useFetch (#​8719)
    • Add initial documentation for router composables (#​8895)
    • Add tls option to redis example (#​8900)
    • Fix syntax errors in server storage example (#​8906)
    • Fix typo (#​8970)
    • api: Add spaces to avoid breaking mobile layout (#​8967)
    • Typo in available (#​8966)
    • Add a bit more detail in the definePageMeta warning to specify it needs to be in a page (#​8923)
    • Match the open graph protocol markup (#​8959)
    • Fix typos (#​8976)
    ❤️ Contributors

    v3.0.0-rc.13

    Compare Source

    👉 Release discussion

    ⭐ What is New?

    🔰 Security Fixes

    This release contains multiple security related fixes #​8675, #​8674 and #​8673 reported via huntr.dev platform by OhB00.

    We recommend you upgrade to the latest version as soon as possible.

    If you encounter "The request URL ... is outside of Vite service allow list" issue, try adding path to vite.server.fs.allow in nuxt.config. read more.

    🚀 Performance Improvements

    Using a new method to extract definePageMeta improves vite performance and makes lazy compilation of pages possible (#​8536).

    💯 Strict Config Schema and Types

    We have cleaned up the configuration schema (#​8487) so that you no longer would be confused with Nuxt 2 options and also can quickly notice any typos in nuxt.config file.

    Typescript strict mode is also enabled by default with this release as best practice. (#​8667)

    🚇 Nitro Development Server Proxy

    Using nitro.devProxy option you can now configure proxies for the development server. (learn more)

    Changelog

    compare changes

    ⚠️ Breaking Changes
    • nuxt: ⚠️ Use parser to generate page metadata (#​8536)
    • schema: ⚠️ Use strict typescript mode by default (#​8667)
    • test-utils: ⚠️ Update vitest args (#​8325)
    • schema: ⚠️ Disable app.pageTransition and app.layoutTransition by default (#​8436)
    • nuxt: ⚠️ Cleanup schema and split nuxt 2 types (#​8487)
    🚀 Enhancements
    • nuxt: Default router scroll behavior (#​3851)
    • nuxt: Make useFetch options reactive (#​8374)
    • kit: Add updateTemplates utility (#​8413)
    • nuxt: Add dev warnings when setPageLayout is used incorrectly (#​8464)
    • Add <devOnly> component (#​7950)
    • nuxt: Allow setting name and path for a route in definePageMeta (#​8633)
    • kit: Add addServerPlugin utility (#​8635)
    • kit, nuxt: Support prerender:routes and addPrerenderRoutes (#​8670)
    🩹 Fixes
    • nuxt: Don't use or assignment (#​8299)
    • nuxt: Pass original request headers to the error page (#​7340)
    • nuxt: Scroll to top on dynamic routes with different params (#​8327)
    • nuxt: Router defaults overwrite custom options always (#​8334)
    • cli: Update analzye main handler (#​8339)
    • nuxt: RouterBehavior comparison for hash block (#​8383)
    • nuxt: Don't load payloads for external urls (#​8370)
    • vite: Invalidate virtual modules with vite-node (#​8389)
    • nuxt: Avoid directly importing vue-router inside <NuxtLayout> (#​8421)
    • webpack: Print build errors (#​8388)
    • kit: Use pathe to resolve aliases (#​8453)
    • test-utils: Override NITRO_PORT as well (#​8458)
    • nuxt: Call data refresh hook in parallel (#​8470)
    • nuxt: Allow responding with custom headers from error.vue (#​8469)
    • schema: Disable early hints by default (#​8486)
    • kit: Don't require nuxt context when resolving path (#​8504)
    • nuxt, nuxi: Improve pages creation and removal DX (#​8502)
    • nuxt: Add vue-router to optimized deps (#​8544)
    • vite: Handle all vite middleware routes (#​8601)
    • nuxt: Pass async-data errors through to client (#​8521)
    • nuxt: Check before appending comma in composable keys (#​8529)
    • nuxt: ⚠️ Use parser to generate page metadata (#​8536)
    • kit: Normalize handler paths (#​8626)
    • nuxt: Don't force prerender / if user doesn't have that route (#​8639)
    • nuxt: Do not inline global styles in html response (#​8666)
    • schema: ⚠️ Use strict typescript mode by default (#​8667)
    • nuxt: Disallow directly rendering error page (#​8673)
    • Resolve ids to support pnpm (#​8671)
    • vite: Enable fs strict mode (#​8674)
    • nuxt: Ensure payload url has no protocol (#​8675)
    💅 Refactors
    • test-utils: ⚠️ Update vitest args (#​8325)
    • schema: ⚠️ Disable app.pageTransition and app.layoutTransition by default (#​8436)
    • nuxt: ⚠️ Cleanup schema and split Nuxt 2 types (#​8487)
    📖 Documentation
    • Add route rules to concepts > rendering (#​8292)
    • Fix broken link (#​8319)
    • Fix link to documentation guide (#​8322)
    • Update website-theme to 0.1.7 (dbc2c8ce)
    • Add missing opening <NuxtLayout> tag in a code sample (#​8349)
    • Update links for external tools (#​8382)
    • Update for clarity and fix typos (#​8375)
    • Add missing app key for transitions (#​8385)
    • api: Add <ClientOnly> to API docs (#​8400)
    • Fix typo (#​8427)
    • Disable transitions by default as hotfix (#​8434)
    • Add note about runtime config serialization (#​8432)
    • Change required node version to be above 16.11 (#​8408)
    • Use LinkExample as block component (#​8459)
    • Add note about early hints and nginx (#​8485)
    • Updated bridge migration guide (#​8471)
    • Mention use case for <KeepAlive> in definePageMeta (#​8491)
    • Update stability edge banners (#​8498)
    • Generate docs for unversioned schema (#​8535)
    • Fix transition wording to include layouts (#​8600)
    • Add information about type checking to typescript.typeCheck config. (#​8632)
    📦 Build
    🏡 Chore
    • renovate: Ignore monorepo dependency upgrades (f934343b)
    • Upgrade vitest to 0.24 (#​6764)
    • nuxt: Add type for headers (#​8326)
    • examples: Add missing dependency and script for testing example (#​8457)
    • Reenable auto-upgrades for vueuse/head (#​8506)
    • Update nitropack to 0.6.1 (5a43e68e)
    ✅ Tests
    ❤️ Contributors
    • Adewale Adeyemi
    • Anthony Fu
    • Christian Burkhart
    • Clément Ollivier
    • Damian Głowala
    • Daniel Roe
    • David Stack
    • Dawid Stefanko
    • Dmitriy
    • Farnabaz
    • Joel
    • Joel Wenzel
    • Johann Schopplich
    • Johnson Chu
    • Josh Deltener
    • Julien Huang
    • Nils
    • Ondřej Misák
    • Pascal Sthamer
    • Pooya Parsa
    • Rajendra
    • Sacha STAFYNIAK
    • Sébastien Chopin
    • Zecka

    v3.0.0-rc.12

    Compare Source

    💬 Release Discussion

    🚀 How to Upgrade

    Note Make sure to recreate the lock file in the project in case of any issues after the upgrade.

    • Automated: npx nuxi@latest upgrade --force
    • Manual: Bump nuxt dependency to 3.0.0-rc.12 and then use npx nuxi@latest cleanup to cleanup any local caches
    ⭐ What is New?
    📍 Route Rules

    RC.12 comes with the first public beta for route rules and hybrid rendering support. Using route rules you can define rules for a group of nuxt routes, change rendering mode or assign a cache strategy based on route! Nuxt server will automatically register corresponding middleware and wrap routes with cache handlers using Nitro caching layer. Whenever possible, route rules will be automatically applied to the deployment platform's native rules (currently Netlify and Vercel are supported).

    👉 See docs for examples and more info.

    ⚗️ Nitropack 0.6

    Nitropack upgraded to 0.6 (Release Notes) and h3 upgraded to 0.8 (Release Notes)

    ⚠️ Breaking changes: Using defineEventHandler() or eventHandler() is now required. If you were previously using a Node.js middleware with (req, res, next?) syntax you need to wrap them with fromNodeMiddleware() to convert it into an h3 handler.

    👦 useHead updates

    This release brings a brand-new version of @vueuse/head with some significant performance improvements and bug fixes. Check out https://github.com/nuxt/framework/pull/8000 for more details, but in particular:

    • Fully-typed usage of useHead
    • No more flickering when transitioning between routes
    • Support ordering of head metadata
    • Faster head hydration and deduping

    ⚠️ Breaking changes: The shortcuts viewport and charset can only be used within nuxt.config and not within useHead directly. For more information on how to update, see https://github.com/nuxt/framework/pull/8000.

    ⚡ Page Meta

    New router options validate and redirect are now supported directly in definePageMeta - so you can perform additional validation for dynamic routes, or implement route redirects directly within pages.

    definePageMeta({
      // redirect: '/admin',
      validate: async (route) => {
        const nuxtApp = useNuxtApp()
        // Check if the id is made up of digits
        return /^\d+$/.test(params.id)
      }
    })
    
    🌅 Early Hints

    Nuxt's node server renderer will now respond with 103 Early Hints before the server renders the app, meaning that you should see a decreased TTFB and earlier resource loading in a supported environment - which at the moment is Chrome with your Nuxt app served over HTTPS with newer than HTTP/1.1.

    📖 Nuxt 3 Docs

    Nuxt's documentation is now written with Nuxt 3's new theming system and the latest Docus and Content module versions. Check it out at https://v3.nuxtjs.org! Expect more coming soon!

    nuxt 3 docs

    Changelog

    compare changes

    🚀 Enhancements
    • nuxt: Support redirect within page metadata (#​7746)
    • cli: Support --dotenv for dev, build and preview commands (#​7660)
    • nuxt: Allow configuring plugins directory (#​7981)
    • nuxt: Add default slot to <NuxtLoadingIndicator> (#​7128)
    • pages: Add validate hook for definePageMeta (#​7870)
    • nuxt: Refresh override for data fetching composables (#​7864)
    • schema, nuxt: Allow user-configurable serverDir (#​7868)
    • nuxt: Parse html to treeshake client-only components (#​7527)
    • nuxt: Wrap #components client exports with createClientOnly (#​7412)
    • nuxt: Add ssr: false route rule to enable SPA mode (#​7938)
    • nuxt: Migrate to latest @vueuse/head (#​8000)
    • nuxt: ⚠️ Add <NuxtPage> to #components (#​8145)
    • nuxt: Add hook debug mode (#​7690)
    • cli: Add nuxi build-module command (#​7610)
    • schema: Add experimental routesRules shortcut (#​7954)
    • kit: Support plugin array for addVitePlugin and addWebpackPlugin (#​8270)
    🔥 Performance
    • nitro: Respond with early hints in node-based environments (#​7893)
    • nuxt: ⚠️ Use component loader to add meta components (#​8167)
    • nuxt: Remove vue-router dependency from minimal app (#​8188)
    • nuxt: Improve link prefetching (#​8225)
    🩹 Fixes
    • nuxt: Export and auto-import clearNuxtData (#​7710)
    • test-utils: Support vitest v0.20.x (#​7712)
    • cli: Include workspaceDir in tsconfig include (#​7726)
    • cli: Stub defineNuxtConfig for nuxi info (#​7728)
    • nuxt: Do not warn for non-existent default layout (#​7748)
    • nuxt: Respect immediate option in useFetch (#​7720)
    • nuxt: Respect baseURL when rendering payload path (#​7809)
    • nuxt: Don't disable scripts in dev mode with experimental noScripts (#​7745)
    • Downgrade Node.js ^16.11.0 requirement to ^16.10.0 (#​7865)
    • nuxt: Handle schema types for relative module paths (#​7946)
    • vite: Add type-checker to client build for ssr: false (#​7930)
    • nuxt: Allow auto-import component with same filename (#​7713)
    • test-utils: Respect setupTimeout (#​7866)
    • nuxt: Fix lazy import of .client components (#​7422)
    • nuxt: Remove fragment from createClientOnly (#​7774)
    • head: Allow using the default slot for script content like noscript (#​7858)
    • nuxt: Don't prerender index.html with a server (#​7831)
    • docs: Link to api config reference (#​8038)
    • docs: Link to installation section (#​8040)
    • nuxt: Page hydration and double load (#​7940)
    • schema: Declare untyped dependency (#​8064)
    • nuxt: Use correct cache and add baseURL to payload (#​7984)
    • cli: Replace lazyHandle with defineLazyHandler (#​8049)
    • schema: Evaluate environment variables when resolving values (#​8079)
    • vite: Prevent overlap between vite assets and app routes (#​7989)
    • nuxt: Don't inline styles for per-request ssr: false (#​8106)
    • nuxt: ⚠️ refresh to override previous requests by default (#​8190)
    • nuxt: Enable router when app/router.options.ts file is present (#​8193)
    • kit: Log module id to the console when import fails (#​8198)
    • nuxt: Avoid head dom update on same route click (#​8206)
    • webpack: Add global to new line (#​8226)
    • schema: RouteRules config (#​8252)
    • cli: Don't includeworkspaceDir in tsconfig by default (#​8256)
    • nuxt: Avoid preloading external routes (#​8255)
    • nuxt: Allow disabling early hints (#​8264)
    • nuxt: Lazy-load entry CSS (#​8278)
    • nuxt: Ignore cache rules for middleware and errors (#​8291)
    💅 Refactors
    • nuxt: Use unref in layout.ts (#​7818)
    • nuxt: Use unref in fetch.ts (#​7813)
    • nuxt: Deprecate <Script> component tag in template (#​8197)
    • nuxt: Use writeEarlyHints from h3 (#​8245)
    • nuxt: Use getRouteRules from nitropack (#​8251)
    📖 Documentation
    • getting-started: Fix typo in views (#​7687)
    • getting-started: Configuration page (#​7689)
    • Recommend to not overwrite some keys in tsconfig (#​7717)
    • directory-structure: Fix typo in server (#​7752)
    • navigate-to: Use await instead of return (#​7734)
    • error-handling: Fix useError() type definition (#​7749)
    • migration: Restructure upgrade guide (#​7730)
    • Document nitro hooks (#​7782)
    • roadmap: Update the release times for v2 and v3 (#​7808)
    • guide: Add nitro plugins to server directory (#​7780)
    • roadmap: Remove not working link from nuxt/auth (#​7781)
    • Updated nuxt bridge migration guide (#​7775)
    • Merge deployment pages in getting started (#​7765)
    • Add newline at end of sass import (#​7810)
    • examples: Optimize writing of : ? (#​7928)
    • Update definePageMeta docs (#​7888)
    • Use nuxt 3 and website theme (#​5479)
    • getting-started: Add transitions page (#​7987)
    • Fix path of nuxt config (#​8021)
    • introduction: Add nuxt key features to the introduction (#​8013)
    • transitions: Add poster for videos (99907dbf)
    • Fix netlify redirects (#​8028)
    • Use webp for 3D gem asset (93c3f30b)
    • Upgrade docus (aef32577)
    • Upgrade docus to fix docsearch input focus (fc2d74a2)
    • Update to [email protected] (3218356d)
    • Fix indentation in "Views" code blocks (#​8039)
    • Fix more redirect issues (#​8045)
    • example: Replace useQuery to getQuery (#​8047)
    • Fix code highlighting (#​8057)
    • Add recommendation for controlling plugin registration order. (#​8096)
    • Add back deleted sections in definePageMeta (c804daa0)
    • Update line number for NuxtHooks source (#​8128)
    • Fix typo (#​8129)
    • Update badges color (bc3016f8)
    • Add app.config route to pre-render (#​8131)
    • Clarify access of RuntimeConfig with Options API (#​8147)
    • Close alert (#​8157)
    • Fix 404 page (#​8136)
    • Use RouterConfig interface in examples (#​8151)
    • Add support for WEBSITE_THEMe env variable (6ad0f3f1)
    • Update route middleware link (#​8196)
    • Adds missing quote in example code (#​8209)
    • Fix validate example (#​8231)
    • Change deprecated useBody with readBody (#​8266)
    • Add spacing between multiple button-link (#​8275)
    • Add cleavr to supported hosting providers (#​8285)
    🌊 Types
    • Include nuxt-link target types (#​8172)
    🏡 Chore
    • Use pnpm for framework monorepo (#​7895)
    • Add start command for stackblitz codeflow (#​8279)
    ⚠️ Breaking Changes
    • nuxt: ⚠️ Add <NuxtPage> to #components (#​8145)
    • nuxt: ⚠️ Use component loader to add meta components (#​8167)
    • nuxt: ⚠️ refresh to override previous requests by default (#​8190)
    ❤️ Contributors
    • Alex
    • Alex C
    • Alexander Lichter
    • Andrew Mudrov
    • Anish Ghimire
    • Anthony Fu
    • AuroraTea
    • Barbapapazes
    • Benicio Cardozo
    • Chenying
    • Christian Preston
    • Cinob
    • Clément Ollivier
    • Cupid Valentine
    • Damian Głowala
    • Daniel Kelly
    • Daniel Roe
    • Daniil Chudo
    • Fumihiro-Yano
    • Harlan Wilton
    • Israel Ortuño
    • James Ray
    • Josh Deltener
    • Julien Huang
    • Krutie Patel
    • Lovue
    • Martin Benndorf
    • Miketromba
    • MiniDigger
    • Mmis1000
    • Niklas
    • Pooya Parsa
    • Rajendra
    • Randy
    • Reinier Kaper
    • Sébastien Chopin
    • Tech Genius
    • Tobias Diez
    • Toni
    • Tuğberk Kılıç
    • Won-hyeok Jung
    • Xezard
    • Yaël Guilloux
    • Yu Yamazaki
    • 菜狗

    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Enabled.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    👻 Immortal: This PR will be recreated if closed unmerged. Get config help if that's undesired.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.

    opened by renovate[bot] 0
  • feat: remove `useHead` artifacts

    feat: remove `useHead` artifacts

    With the module removing scripts from the HTML, there are a few artifacts left over which aren't being used for anything.

    This PR removes Nuxt core ones (useHead) and pre-fetch API links from @nuxt/content.

    I'm interested in your thoughts, and quite happy to close this PR if you think it doesn't belong.

    It may cause issues if / when island hydration is supported and I haven't done much coverage with the tests.

    opened by harlan-zw 2
  • Dependency Dashboard

    Dependency Dashboard

    This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

    Awaiting Schedule

    These updates are awaiting their schedule. Click on a checkbox to get an update now.

    • [ ] chore(deps): lock file maintenance

    Open

    These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

    Detected dependencies

    github-actions
    .github/workflows/ci.yml
    • actions/checkout v3
    • actions/setup-node v3
    • actions/checkout v3
    • actions/setup-node v3
    • codecov/codecov-action v3
    .github/workflows/codeql.yml
    • actions/checkout v3
    • github/codeql-action v2
    • github/codeql-action v2
    • github/codeql-action v2
    npm
    package.json
    • @nuxt/kit ^3.0.0-rc.11
    • pathe ^1.0.0
    • @nuxt/module-builder ^0.1.7
    • @nuxt/schema 3.0.0-rc.9-27703329.537338f
    • @nuxt/test-utils 3.0.0-rc.11
    • @nuxtjs/eslint-config-typescript 12.0.0
    • @release-it/conventional-changelog 5.1.1
    • @types/node 18.11.18
    • @vitest/coverage-c8 0.26.3
    • c8 7.12.0
    • conventional-changelog-conventionalcommits 5.0.0
    • eslint 8.31.0
    • eslint-config-prettier 8.6.0
    • eslint-plugin-prettier 4.2.1
    • husky 8.0.3
    • lint-staged 13.1.0
    • nuxt 3.0.0-rc.9-27703329.537338f
    • pinst 3.0.0
    • prettier 2.8.1
    • release-it 15.6.0
    • typescript 4.9.4
    • vitest 0.26.3
    • vue 3.2.45
    • node 18.13.0
    • pnpm 7.22.0
    playground/package.json
    • nuxt ^3.0.0-rc.11

    • [ ] Check this box to trigger a request for Renovate to run again on this repository
    opened by renovate[bot] 0
Releases(0.1.3)
Owner
Daniel Roe
Daniel Roe
Nuxt eureka client

Nuxt eureka client

Kirill 5 May 30, 2022
Restream is a module that allows you to create a stream of an audio/video file from the Firebase storage, protected from direct download through the client-side.

nuxt-restream Restream is a module that allows you to create a stream of an audio/video file from the Firebase storage, protected from direct download

Restorm 3 Dec 13, 2022
Easily connect your Nuxt 3 application with LogSnag 📰

Nuxt LogSnag ?? LogSnag integration for Nuxt 3 ✨ Release Notes Features Nuxt 3 ready Easy integration Handy composables TypeScript support Setup Insta

Conner 13 Apr 28, 2022
Easily remove all refs from an object using the `deepUnref`-composable.

Vue - Deep Unrefs Similar to unref(), easily remove all refs recursively from an object using the deepUnref-composable. ?? Get Started Luckily, it's i

Open Web 4 May 19, 2022
Easily remove all refs from an object using the `deepUnref`-composable.

Vue - Deep Unrefs Similar to unref(), easily remove all refs recursively from an object using the deepUnref-composable. ?? Get Started Luckily, it's i

Open Web Foundation 4 May 19, 2022
Nuxt.js module to use Unleash toggle feature services

nuxt-unleash Nuxt.js module to use Unleash toggle feature services ?? Release Notes Features Use $unleash to access and handle your Unleash feature fl

Juanjo Conejero 15 Dec 3, 2022
Easy generation of OpenGraph & Twitter meta-tags in Nuxt 3 📋

nuxt-social-tags Easy generation of OpenGraph & Twitter meta-tags in Nuxt 3 ✨ Release Notes ?? Read the documentation Features Nuxt3 ready Composables

Conner 19 Dec 17, 2022
Nuxt 3 starter with Algolia, Storyblok, and Indexer

Nuxt 3 with Storyblok CMS and Algolia Search (incl. automatic indexing) This is a demo repository for an article in Dev.to. We recommend to look at th

Jakub Andrzejewski 5 May 24, 2022
End-to-end typesafe APIs with tRPC.io in Nuxt applications.

tRPC-Nuxt End-to-end typesafe APIs with tRPC.io in Nuxt applications. The client above is not importing any code from the server, only its type declar

Robert Soriano 231 Dec 30, 2022
A modern, zero-dependency uptime monitoring tool & status page based on GitHub Actions & Nuxt Content v2.

StatusBase Uptime monitoring tool & beautiful status pages Powered by Nuxt Content v2! Free • Open Source • Notification View Demo · Report Bug · Requ

zernonia 208 Dec 27, 2022
🔎 Algolia module for Nuxt

@nuxtjs/algolia Algolia module for Nuxt ✨ Release Notes ?? Read the documentation Features Nuxt 3 ready Easy integration with Algolia Handy composable

Nuxt Community 128 Jan 7, 2023
Nuxt 3 module for Kirby's Query Language API

nuxt-kql Kirby KQL module for Nuxt 3. This module provides a useKql composable, which under the hood uses useFetch. Thus, KQL query fetching in your N

Johann Schopplich 25 Dec 15, 2022
This repo contains a fully configured nuxt 3 instance supporting TypeScript and several considered as useful libraries, fully configured and ready to use in real world projects!

Nuxt 3 Starter This repo contains a fully configured nuxt 3 instance supporting TypeScript and several considered as useful libraries, fully configure

Ali Soueidan 26 Dec 27, 2022
Batteries-included, zero-config Ionic integration for Nuxt

Nuxt Ionic Ionic integration for Nuxt ✨ Changelog ?? Read the documentation ▶️ Online playground Features ⚠️ nuxt-ionic is currently a work in progres

Daniel Roe 211 Dec 28, 2022
Http-proxy middleware for Nuxt 3.

nuxt-proxy Http-proxy middleware for Nuxt 3. Installation npm install nuxt-proxy Usage export default defineNuxtConfig({ modules: ['nuxt-proxy'],

Robert Soriano 49 Dec 30, 2022
Nuxt 3 module for Web3.js

nuxt-web3.js Nuxt 3 module for Web3.js. Installation npm install nuxt-web3.js Usage export default defineNuxtConfig({ modules: ['nuxt-web3.js'], })

Robert Soriano 8 Dec 16, 2022
OpenID-Connect(OIDC) integration module for nuxt 3.0.

Nuxt OpenID-Connect OpenID-Connect(OIDC) integration module for nuxt 3.0. Features An Nuxt 3 module. OIDC integration ( implemetation base openid-clie

Aborn Jiang 10 Dec 24, 2022
🔎 Meilisearch module for Nuxt 3

nuxt-meilisearch Meilisearch module for Nuxt Features Nuxt 3 Easy integration with MeilisearchJS lib Support for Vue Algolia Vue 3 InstantSearch compo

Alex Duval 50 Dec 26, 2022
A modern, zero-dependency uptime monitoring tool & status page based on GitHub Actions & Nuxt Content v2.

StatusBase Uptime monitoring tool & beautiful status pages Powered by Nuxt Content v2! Free • Open Source • Notification View Demo · Report Bug · Requ

StatusBase 194 Jul 5, 2022