Skip to content

Usage with Nuxt 3 #47

Answered by MelihAltintas
meister-eder asked this question in Q&A
Nov 23, 2021 · 3 comments · 6 replies
Discussion options

You must be logged in to vote

Hello,

you don't need to add vue3-openlayers to buildmodules. You can use as a plugin.

Nuxt will automatically read the files in your plugins directory and load them. You can use .server or .client suffix in the file name to load a plugin only on the server or client side.

All plugins in your plugins/ directory are auto-registered, so you should not add them to your nuxt.config separately.

Please star the project, If you like it :)

Example usage of nuxt3 : https://codesandbox.io/s/vue3-openlayers-nuxt-forked-e3rfy?file=/plugins/vue3-openlayers.client.js

Replies: 3 comments 6 replies

Comment options

You must be logged in to vote
2 replies
@iBobik
Comment options

@meister-eder
Comment options

Answer selected by MelihAltintas
Comment options

You must be logged in to vote
1 reply
@smorcuend
Comment options

Comment options

You must be logged in to vote
3 replies
@jsolly
Comment options

@arbaev
Comment options

@jsolly
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
6 participants
Converted from issue

This discussion was converted from issue #46 on November 24, 2021 10:37.