2
0
mirror of https://github.com/tenrok/vue-meta.git synced 2026-05-28 10:54:04 +03:00
Commit Graph

576 Commits

Author SHA1 Message Date
pimlie 2adba84e58 refactor: combine escape info 2019-03-12 10:03:46 +01:00
pimlie a9d46888ce chore: remove unused rollup-plugin-buble 2019-03-12 10:03:46 +01:00
pimlie 077407297b chore: improve build config 2019-03-12 10:03:46 +01:00
pimlie 012873c9ac chore: add audit to ci 2019-03-12 10:03:46 +01:00
pimlie 749f8d6228 chore: update circlici config for e2e tests 2019-03-12 10:03:46 +01:00
pimlie 2b24acc8b2 refactor: set defaultOptions in shared/constants 2019-03-12 10:03:46 +01:00
pimlie c1f97c4ea4 refactor: move isArray into is-type 2019-03-12 10:03:46 +01:00
pimlie bfa64af29b chore: add missing dep 2019-03-12 10:03:46 +01:00
pimlie c691674612 chore: update circlci config for e2e tests 2019-03-12 10:03:46 +01:00
pimlie 5cbb5bdc52 refactor: use forEach not map 2019-03-12 10:03:46 +01:00
pimlie a10fd83539 chore: update dependencies 2019-03-12 10:03:46 +01:00
pimlie 05b8891110 test: add e2e tests
fix: boolean attributes client side
2019-03-12 10:03:46 +01:00
pimlie a853ce3de7 Revert "refactor: remove beforeMount hook"
This reverts commit 3a6374e2afa57e624c60e42277f71edc998f1f9f.
2019-03-12 10:03:46 +01:00
pimlie 18fd23d3c0 refactor: remove beforeMount hook
This shouldnt be necessary anymore because we force initialization once on mounted/nextTick. Using beforeMount is also inherently less optimal because you are unlikely to benefit from walking the component tree as beforeMount is called before all child components are loaded. So using beforeMount resulted probably that for every component which uses metaInfo a refresh was called on load.

A possible caveat that may exists due to removing beforeMount in favor of a single refresh is that it takes longer for your metaInfo to be updated if you have a lot of components on your page, not sure if this will be a problem in real world scenarios because if this is a problem you should probably be using ssr anyway. Also the v1 docs state that using beforeMount also results in a single update (although in practice it could be more then one)
2019-03-12 10:03:46 +01:00
pimlie f490a48b99 refactor: small improvements (mainly tests) 2019-03-12 10:03:46 +01:00
pimlie 5ad671169b fix: dont call changed with explicit this
in refresh this is probably not the component changed was defined on, removing call(this) gives context control back to the user
2019-03-12 10:03:46 +01:00
pimlie 5f8025e126 test: increase coverage, add missing tests
fix: issues discovered by adding missing tests
2019-03-12 10:03:46 +01:00
pimlie ce7eaf56d3 test: add missing test for sanitizeByTagId
fix: broken sanitizeByTagId implementation
2019-03-12 10:03:46 +01:00
pimlie da4bb27a4b refactor: just pass all options to getComponentOption 2019-03-12 10:03:46 +01:00
pimlie c9a732c9d7 test: add generator/updater test for array attributes 2019-03-12 10:03:46 +01:00
pimlie 9d8ea758ac refactor: prefer ternary 2019-03-12 10:03:46 +01:00
Alexander Lichter 6f1b080654 refactor: prefer destruct syntax
Co-Authored-By: pimlie <pimlie@hotmail.com>
2019-03-12 10:03:46 +01:00
pimlie 01edc8c242 feat: attr keys can have array values (resolves #231) 2019-03-12 10:03:46 +01:00
pimlie 6e18a7d54a chore: fix lint 2019-03-12 10:03:46 +01:00
pimlie 104113a7b8 fix: use undefined as child ignore indicator 2019-03-12 10:03:46 +01:00
pimlie 915fedfb7f feat: child can indicate parent vmid to be removed (resolves: #288) 2019-03-12 10:03:46 +01:00
pimlie 22e456cbe2 feat: child can indicate its content should be ignored (resolves: #204) 2019-03-12 10:03:46 +01:00
pimlie 4dafffea4e refactor: prefer forEach 2019-03-12 10:03:46 +01:00
pimlie b7ee0409ea feat: add amp as boolean attribute (resolves: #311) 2019-03-12 10:03:46 +01:00
pimlie 6bea7f45f4 test: fix escape test as we only escape keys which are used in html 2019-03-12 10:03:46 +01:00
pimlie 7615f4120c fix: ignore data when its not an object (fixes: #253, #279, #297) 2019-03-12 10:03:46 +01:00
pimlie 23c3380c90 refactor: optimize getComponentOption by making it less generic 2019-03-12 10:03:46 +01:00
pimlie 7b888c9437 refactor: optimize getMetaInfo by extracting functions
this should make it easier for javascript engines to optimize these functions
2019-03-12 10:03:46 +01:00
pimlie 12c7949132 fix: dont updateTags when the new info is not an array 2019-03-12 10:03:46 +01:00
pimlie 4fc67df86a refactor(build): use babel instead of buble 2019-03-12 10:03:46 +01:00
pimlie cd98210acb refactor: make hasMetaInfo default export 2019-03-12 10:03:46 +01:00
pimlie f2e8eb537d feat: track branches which contain metaInfo components 2019-03-12 10:03:46 +01:00
pimlie fa90902fc7 refactor: extract applyTemplate method and make it more generic 2019-03-12 10:03:46 +01:00
pimlie 15eb9ccfd1 refactor: extract merge methods 2019-03-12 10:03:46 +01:00
pimlie 95ba9c0291 refactor: extract escape method 2019-03-12 10:03:46 +01:00
pimlie 31e975d312 feat: add getOptions method (resolves: #215) 2019-03-12 10:03:46 +01:00
Sébastien Chopin 3db250dfea Merge pull request #324 from pimlie/feat-more-refactor
feat: refresh once on navigation & es build
2019-03-06 14:52:31 +01:00
pimlie 722786d803 fix: add afterNavigation type 2019-03-05 15:21:19 +01:00
pimlie ba4fd1b321 chore: fix example import 2019-03-05 15:15:51 +01:00
pimlie 41a649fc57 chore: update toc 2019-03-05 15:13:51 +01:00
pimlie 97badf61cb feat: add afterNavigation callback (fix: #259) 2019-03-05 15:11:25 +01:00
pimlie 173b31d1d7 feat: export hasMetaInfo helper function 2019-03-05 14:17:28 +01:00
pimlie f597f61104 Revert "feat: use named exports to export helper functions"
This reverts commit 95c3b7d4e8.
2019-03-05 14:12:56 +01:00
pimlie 95c3b7d4e8 feat: use named exports to export helper functions 2019-03-05 14:06:21 +01:00
pimlie 9c80dab7b2 fix: use single object prop on
feat: provide hasMetaInfo export for other libraries to check if metaInfo has been defined

chore: deprecate _hasMetaInfo
2019-02-23 13:49:37 +01:00