Skip to content

Releases: vuejs/repl

v4.1.1

14 Feb 03:12
v4.1.1
77368bb
Compare
Choose a tag to compare

   🐞 Bug Fixes

  • Reload preview style error after switching theme  -  by @btea in #214 (bc4c7)
  • Add vue import maps for default import map  -  by @sxzz (c7467)
    View changes on GitHub

v4.1.0

11 Feb 01:46
v4.1.0
9e1b761
Compare
Choose a tag to compare

   🚀 Features

    View changes on GitHub

v4.0.2

10 Feb 12:15
v4.0.2
1786cbf
Compare
Choose a tag to compare

   🐞 Bug Fixes

  • Respect vue version at initialization  -  by @sxzz (ef220)
    View changes on GitHub

v4.0.1

10 Feb 10:58
v4.0.1
767bc54
Compare
Choose a tag to compare

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v4.0.0

10 Feb 09:03
v4.0.0
9fd15ba
Compare
Choose a tag to compare

Notable Changes

  • ReplStore is an interface instead of a class. Replace new ReplStore() with useStore().
  • sfcOptions is removed from props, and renamed options to sfcOptions in store.
  • Removed store.state property and merged it as the top level of Store.
  • Moved serializedState as the second argument of useStore.
  • Removed StoreOptions and merged to StoreState.
  • Removed customElement option, now get it from sfcOptions.script.customElement.
  • defaultVueRuntimeURL, defaultVueRuntimeProdURL, defaultVueServerRendererURL is removed from useStore, use useVueImportMap instead.

Please take a look at d01bf55 for full changes.

Migration Guide

Please read Advanced Usage first.

ReplStore Usage

  • Replace new ReplStore() with useStore().

  • The first parameter accepted by useStore is a Ref Map; please use ref to wrap the options.

     const sfcOptions = ref({})
     useStore({ sfcOptions })
  • Methods like store.setVueVersion and store.toggleProduction have been removed. Please manually pass the ref and directly assign values to it.

    store.vueVersion = '3.4.6'
  • Moved serializedState as the second argument of useStore.

     const store = useStore(
       {}, // initial state
       // initialize repl with previously serialized state
       location.hash,
     )

useVueImportMap

  • The logic related to Vue versions has been abstracted to useVueImportMap.
     const {
       importMap: builtinImportMap,
       vueVersion,
       productionMode,
     } = useVueImportMap({
       // specify the default URL to import Vue runtime from in the sandbox
       // default is the CDN link from jsdelivr.com with version matching Vue's version
       // from peerDependency
       runtimeDev: 'cdn link to vue.runtime.esm-browser.js',
       runtimeProd: 'cdn link to vue.runtime.esm-browser.prod.js',
       serverRenderer: 'cdn link to server-renderer.esm-browser.js',
       vueVersion: 'initial vue version'
     })
     
     const store = useStore({
       builtinImportMap,
       vueVersion,
     })

See Usage Diff


   🚨 Breaking Changes

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v4.0.0-beta.0

10 Feb 08:24
v4.0.0-beta.0
804e1ff
Compare
Choose a tag to compare
v4.0.0-beta.0 Pre-release
Pre-release

   🚨 Breaking Changes

   🐞 Bug Fixes

    View changes on GitHub

v4.0.0-alpha.1

24 Jan 14:04
v4.0.0-alpha.1
fd3c955
Compare
Choose a tag to compare
v4.0.0-alpha.1 Pre-release
Pre-release

   🐞 Bug Fixes

    View changes on GitHub

v3.4.0

24 Jan 15:08
v3.4.0
21d49e4
Compare
Choose a tag to compare

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v4.0.0-alpha.0

21 Jan 08:32
v4.0.0-alpha.0
97ac09b
Compare
Choose a tag to compare
v4.0.0-alpha.0 Pre-release
Pre-release

   🚨 Breaking Changes

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub

v3.3.0

11 Jan 07:23
v3.3.0
874fd74
Compare
Choose a tag to compare

   🚀 Features

   🐞 Bug Fixes

    View changes on GitHub