Skip to content

A bunch of fixes for the next branch #55

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Oct 21, 2020

Conversation

LeBenLeBen
Copy link
Contributor

Sorry I couldn’t come with a better title 😅

I tested the next branch within a project and came across a couple of issues. Here are the changes I made to make it work.

Otherwise the event onChange is triggered twice, once by PrismEditor textarea (payload: Event) and once by the Editor (payload: code string)
@@ -61,6 +61,7 @@ const highlight = (lang, jsxInExamples) => {

export default {
name: "VueLiveEditor",
inheritAttrs: false,
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just curious. Why was this one necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Otherwise the @change defined in VueLive.vue is inherited by PrismEditor component in Editor.vue. Then, when the editor value changes, it trigger the event twice; once by PrismEditor textarea (payload: Event, undesired) and once by the Editor (payload: code string, desired).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh !! good call.

@elevatebart elevatebart merged commit 83b415a into vue-styleguidist:next Oct 21, 2020
elevatebart pushed a commit that referenced this pull request Oct 21, 2020
* refactor: abandon functional components

* fix: avoid warning of VueLiveDefaultLayout made reactive

* fix: prevent PrismEditor from inheriting Editor props

Otherwise the event onChange is triggered twice, once by PrismEditor textarea (payload: Event) and once by the Editor (payload: code string)

* fix: externalize Vue from library bundle
elevatebart added a commit that referenced this pull request May 1, 2022
* fix: first compiling version

* fix: demo remove use of datepicker unused

* First release of a vue 3 compatible vue-live (#53)

* feat: new next configuration for sem rel

BREAKING CHANGE:  will deliver the next branch as alpha next

* fix: hook on the right event

* fix: use global h hyperscript

* fix: protect empty script

* fix: install vue-3 datepicker

* docs: use the new date picker

* docs: add a comment

* build: ren semantic on next

* build: run travis on next branch

* test: fix cypress

* fix: A bunch of fixes for the next branch (#55)

* refactor: abandon functional components

* fix: avoid warning of VueLiveDefaultLayout made reactive

* fix: prevent PrismEditor from inheriting Editor props

Otherwise the event onChange is triggered twice, once by PrismEditor textarea (payload: Event) and once by the Editor (payload: code string)

* fix: externalize Vue from library bundle

* docs: fix vue aliases

* docs: update path of vuejs

* Update README.md

* fix: use acorn walk instead of recast visit

For vite esm compat

* fix: remove recast remains

* style: update comment

* fix: allow aria and dashed attributes

closes #59

* test: update test to make colon acceptable

* fix: CSS scope ID (#64)

* chore: release alpha 6

* fix: ci update caniuse

* fix: allow for $ variables and functions handlers

* build: vue plugin before others for sfc

* fix: release semrel

* feat: create allow list for camelCased SVG attributes (#67)

Co-authored-by: Michael Dodge <[email protected]>

* fix: make npm start work again

* fix: make it run without eslint errors

* fix: make it run

* fix: update dependency and make jsx work

* build: eslint configuration

* build: fix unit test using jest

* fix: update inbrowser compiler for vite compat

* fix: remove console.log

* ci: remove travis from vue-live

Co-authored-by: Benoît Burgener <[email protected]>
Co-authored-by: Maksym Shopynskyi <[email protected]>
Co-authored-by: mgdodge <[email protected]>
Co-authored-by: Michael Dodge <[email protected]>
elevatebart added a commit that referenced this pull request Jun 2, 2022
* fix: first compiling version

* fix: demo remove use of datepicker unused

* First release of a vue 3 compatible vue-live (#53)

* feat: new next configuration for sem rel

BREAKING CHANGE:  will deliver the next branch as alpha next

* fix: hook on the right event

* fix: use global h hyperscript

* fix: protect empty script

* fix: install vue-3 datepicker

* docs: use the new date picker

* docs: add a comment

* build: ren semantic on next

* build: run travis on next branch

* test: fix cypress

* fix: A bunch of fixes for the next branch (#55)

* refactor: abandon functional components

* fix: avoid warning of VueLiveDefaultLayout made reactive

* fix: prevent PrismEditor from inheriting Editor props

Otherwise the event onChange is triggered twice, once by PrismEditor textarea (payload: Event) and once by the Editor (payload: code string)

* fix: externalize Vue from library bundle

* docs: fix vue aliases

* docs: update path of vuejs

* Update README.md

* fix: use acorn walk instead of recast visit

For vite esm compat

* fix: remove recast remains

* style: update comment

* fix: allow aria and dashed attributes

closes #59

* test: update test to make colon acceptable

* fix: CSS scope ID (#64)

* chore: release alpha 6

* fix: ci update caniuse

* fix: allow for $ variables and functions handlers

* build: vue plugin before others for sfc

* fix: release semrel

* feat: create allow list for camelCased SVG attributes (#67)

Co-authored-by: Michael Dodge <[email protected]>

* fix: make npm start work again

* fix: make it run without eslint errors

* fix: make it run

* fix: update dependency and make jsx work

* build: eslint configuration

* build: fix unit test using jest

* fix: update inbrowser compiler for vite compat

* fix: remove console.log

* fix: build script with vite needs ordering of imports

* ci: run release on next

Co-authored-by: Benoît Burgener <[email protected]>
Co-authored-by: Maksym Shopynskyi <[email protected]>
Co-authored-by: mgdodge <[email protected]>
Co-authored-by: Michael Dodge <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants