@OSUblake following your hint I found now the following in Nuxt Docs. Probably this is the way to go?
Name conventional plugin
If plugin is assumed to be run only in client or server side, .client.js or .server.js can be applied as extension of plugin file, the file will be automatically included in corresponding side.
Example:
nuxt.config.js:
export default {
plugins: [
'~/plugins/foo.client.js', // only in client side
'~/plugins/bar.server.js', // only in server side
'~/plugins/baz.js' // both client & server
]
}
Object syntax
You can also use the object syntax with the mode property ('client' or 'server') in plugins.
Example:
nuxt.config.js:
export default {
plugins: [
{ src: '~/plugins/both-sides.js' },
{ src: '~/plugins/client-only.js', mode: 'client' }, // only on client side
{ src: '~/plugins/server-only.js', mode: 'server' } // only on server side
]
}