Skip to content

Commit 0bdc4b3

Browse files
authored
feat: add detector for @vue/composition-api (#48)
1 parent 97d472a commit 0bdc4b3

File tree

2 files changed

+14
-0
lines changed

2 files changed

+14
-0
lines changed

README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@ To support a new UI library, please look at [detectors/uis.json](detectors/uis.j
6262
- [Vue Formulate](https://vueformulate.com/)
6363
- [Inertia.js](https://inertiajs.com)
6464
- [vee-validate](https://vee-validate.logaretm.com)
65+
- [Vue Composition API](https://github.com/vuejs/composition-api)
6566

6667
To support a new Vue plugin, please look at [detectors/plugins.json](detectors/plugins.json).
6768

detectors/plugins.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,17 @@
11
{
2+
"@vue/composition-api": {
3+
"metas": {
4+
"slug": "composition-api",
5+
"name": "@vue/composition-api",
6+
"imgPath": null,
7+
"url": "https://github.com/vuejs/composition-api"
8+
},
9+
"detectors": {
10+
"js": [
11+
"[...document.querySelectorAll('*')].map((el) => Boolean(el.__vue__?.__composition_api_state__)).filter(Boolean).length"
12+
]
13+
}
14+
},
215
"vue-router": {
316
"metas": {
417
"slug": "vue-router",

0 commit comments

Comments
 (0)