mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-23 14:15:13 +00:00
add font to global-css example
This commit is contained in:
parent
696ada09c4
commit
5eeca5a41b
BIN
examples/global-css/assets/roboto.woff2
Normal file
BIN
examples/global-css/assets/roboto.woff2
Normal file
Binary file not shown.
@ -1,3 +1,11 @@
|
||||
@font-face {
|
||||
font-family: 'Roboto';
|
||||
font-style: normal;
|
||||
font-weight: 400;
|
||||
src: local('Roboto'), local('Roboto-Regular'), url(../assets/roboto.woff2) format('woff2');
|
||||
unicode-range: U+0460-052F, U+20B4, U+2DE0-2DFF, U+A640-A69F;
|
||||
}
|
||||
|
||||
body {
|
||||
background: #eee;
|
||||
text-align: center;
|
||||
@ -7,6 +15,7 @@ body {
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0;
|
||||
font-family: 'Roboto';
|
||||
}
|
||||
.content {
|
||||
margin-top: 100px;
|
||||
|
@ -9,5 +9,12 @@ module.exports = {
|
||||
css: [
|
||||
'bulma/css/bulma.css',
|
||||
'~/css/main.css'
|
||||
]
|
||||
],
|
||||
render: {
|
||||
bundleRenderer: {
|
||||
shouldPreload: (file, type) => {
|
||||
return ['script', 'style', 'font'].includes(type)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user