Skip to content
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

Есть пример использования с Nuxt 3? #458

Closed
kllpff opened this issue May 8, 2023 · 1 comment
Closed

Есть пример использования с Nuxt 3? #458

kllpff opened this issue May 8, 2023 · 1 comment

Comments

@kllpff
Copy link

kllpff commented May 8, 2023

Всем привет! Не могу завести с nuxt 3, может есть у кого пример?

Создал в plugins ymapPlugin.js, в нём след. код:
`import YmapPlugin from 'vue-yandex-maps'

const settings = {
apiKey: 'ХХХХ',
lang: 'ru_RU',
coordorder: 'latlong',
enterprise: false,
version: '2.1',
}

export default defineNuxtPlugin(nuxtApp => {
nuxtApp.vueApp.use(YmapPlugin, settings)
})
`

В компоненете в mounted делаю await loadYmap, но получаю ошибку, что loadYmap is not defined.

@kllpff kllpff closed this as completed May 8, 2023
@kllpff
Copy link
Author

kllpff commented May 8, 2023

решил проблему, не видел другую версию

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant