Closed ruscon closed 7 years ago
/** * Download Google fonts to webpack build folder using google-webfonts-helper * Reference: https://github.com/gabiseabra/google-fonts-webpack-plugin */ new GoogleFontsPlugin({ fonts: [ { family : 'Lobster', subsets : ['cyrillic'] }, { family : 'Comfortaa', variants: ['300,400,700'], subsets : ['cyrillic'] }, { family : 'Oswald', variants: ['200,300,400,500,600'], subsets : ['cyrillic'] } ], path : 'fonts/' /* ...options */ })
all font files downloaded
font.css file only one font
/* === Lobster - regular */ @font-face { font-family: 'Lobster'; font-style: normal; font-weight: 400; src: url("./fonts/Lobster-Regular.eot"); src: local("Lobster"), local("Lobster-Regular"), url("./fonts/Lobster-Regular.eot") format("embedded-opentype"), url("./fonts/Lobster-Regular.woff2") format("woff2"), url("./fonts/Lobster-Regular.woff") format("woff"), url("./fonts/Lobster-Regular.ttf") format("truetype"), url("./fonts/Lobster-Regular.svg") format("svg"); }
Sorry, resolved
Wrong format
variants: ['200,300,400,500,600'],
Should be
variants: ['300', '400', '500', '700'],
all font files downloaded
font.css file only one font