Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit a8d7d75

Browse files
committed
chore: release v0.23.0
1 parent 60d7416 commit a8d7d75

File tree

2 files changed

+39
-1
lines changed

2 files changed

+39
-1
lines changed

CHANGELOG.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,41 @@
1+
## [0.23.0](https://github.com/nuxt-community/composition-api/compare/0.22.4...0.23.0) (2021-04-12)
2+
3+
4+
### ⚠ BREAKING CHANGES
5+
6+
* `@nuxtjs/composition-api/module` is now how the module should be imported in `nuxt.config`
7+
8+
* There is no longer a need to amend `moduleNameMapper` in your jest.config - you should remove any entry for `@nuxtjs/composition-api` there. When used outside a Nuxt context, the module will 'auto-mock' and use https://github.com/nuxt-community/composition-api/blob/be94d4f4e1321565864dd3d3d5e850f7cabf6ca9/src/globals.ts instead of live Nuxt configuration.
9+
10+
* `@nuxtjs/composition-api/babel` has been renamed to `@nuxtjs/composition-api/dist/babel-plugin`.
11+
12+
* `@vue/composition-api` is no longer transpiled by default. You should consider adding it to `build.transpile`, but note that you may also need to add any other libraries that also use `@vue/composition-api`.
13+
14+
* You should ensure you haven't named any layout '0' as this will conflict with how this package is registering the Vue Composition API.
15+
16+
* `defineNuxtConfig`, `defineNuxtModule` and `defineNuxtServerMiddleware` have been removed. You can create your own helper with the following code:
17+
```ts
18+
import { Module, ServerMiddleware, NuxtConfig } from '@nuxt/types'
19+
20+
export const defineNuxtModule = <T extends Record<string, unknown>>(module: Module<T>) => module
21+
export const defineNuxtServerMiddleware = (serverMiddleware: ServerMiddleware) => serverMiddleware
22+
export const defineNuxtConfig = (config: NuxtConfig) => config
23+
```
24+
25+
### Bug Fixes
26+
27+
* register the composition api in a template file ([#433](https://github.com/nuxt-community/composition-api/issues/433)) ([8cc21ce](https://github.com/nuxt-community/composition-api/commit/8cc21ce2de08fbb12d0561c9bbd5c76ecfa32e08)), closes [#415](https://github.com/nuxt-community/composition-api/issues/415) [#391](https://github.com/nuxt-community/composition-api/issues/391)
28+
* return `from` rather than `redirectedFrom` from `useContext` ([a159d87](https://github.com/nuxt-community/composition-api/commit/a159d8781a0eef9071af05bbf1092061b8b653e2)), closes [#444](https://github.com/nuxt-community/composition-api/issues/444)
29+
30+
31+
### Code Refactoring
32+
33+
* change how library is imported ([#418](https://github.com/nuxt-community/composition-api/issues/418)) ([5bb1a72](https://github.com/nuxt-community/composition-api/commit/5bb1a72669f97ba964dd3968f76627472c502dca))
34+
- fixed an issue with `nuxt-vite` compatbility
35+
* significant packaging changes ([#438](https://github.com/nuxt-community/composition-api/issues/438)) ([ddc9c0f](https://github.com/nuxt-community/composition-api/commit/ddc9c0f9ba8281931da817b3d106d0a45a2b4cf9))
36+
- The ESM version of the library is now `.mjs` (but we polyfill support for this and other `.mjs` files in webpack 4).
37+
- This library is now located within `node_modules` rather than being templated, with a limited template for the config.
38+
139
### [0.22.4](https://github.com/nuxt-community/composition-api/compare/0.22.3...0.22.4) (2021-03-23)
240

341

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@nuxtjs/composition-api",
3-
"version": "0.22.4",
3+
"version": "0.23.0",
44
"description": "Composition API hooks for Nuxt",
55
"keywords": [
66
"vue",

0 commit comments

Comments
 (0)