mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-25 23:22:02 +00:00
docs: add warning about dynamic import of css (#21805)
This commit is contained in:
parent
e49645bfb9
commit
dc329c32aa
@ -18,7 +18,11 @@ You can use a javascript import, or a css [`@import` statement](https://develope
|
||||
|
||||
```vue [pages/index.vue]
|
||||
<script>
|
||||
// Use a static import for server-side compatibility
|
||||
import '~/assets/css/first.css'
|
||||
|
||||
// Caution: Dynamic imports are not server-side compatible
|
||||
import('~/assets/css/first.css')
|
||||
</script>
|
||||
|
||||
<style>
|
||||
|
Loading…
Reference in New Issue
Block a user