Remeic / vue-highlighter

🏷 Vue directive for highlight multiple istances of a word
MIT License
39 stars 13 forks source link

Export lib as Vue Plugin #8

Closed jtommy closed 6 years ago

jtommy commented 6 years ago

@Remeic I changed the export way of your library as Vue Plugin. As you can see it's a breaking change (i didn't update Readme) but i think it's the better way to share a custom library in order to add new features (components, directives, mixins, ...) in the future. For CDN the plugin is automatically added to Vue instance.

codecov[bot] commented 6 years ago

Codecov Report

Merging #8 into master will decrease coverage by 1.44%. The diff coverage is 98.55%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master       #8      +/-   ##
==========================================
- Coverage     100%   98.55%   -1.45%     
==========================================
  Files           1        2       +1     
  Lines          66       69       +3     
==========================================
+ Hits           66       68       +2     
- Misses          0        1       +1
Impacted Files Coverage Δ
src/highlighter.js 100% <100%> (ø)
src/index.js 75% <75%> (-25%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 3f7fef1...adb476b. Read the comment docs.

Remeic commented 6 years ago

Hi @jtommy ( Ciao!! ), thanks for contributing, you know how write test for the new index.js? Because the code coverage is decreased

Thanks again

jtommy commented 6 years ago

I added an example but it doesn't cover all code (for example: window branch)

Remeic commented 6 years ago

Perfect, thanks Walter! 🚀