Closed iham closed 10 years ago
Thanks iham,
I just finished splitting the code off to a more isolated npm module. I'll copy your changes into that repo manually if you like, then add the grunt options back in here.
Hi iham,
I have merged the options into https://github.com/agentk/fontfacegen
The new options are collate
and embed
. Collate will separate out the fonts into subfolders and embed takes and array of the files types to embed.
The options are now available from both the grunt and gulp plugin as options are passed directly to the fontfacegen module.
Any issues just let me know.
hi agentk,
based on grunt-webfont i've added embed base64 for woff and ttf based on the embed option. a second thing i've changed: the folder structure: it's now based on the font name
lets say this config ... build: { options: { path_prefix: '../fonts/', stylesheet: 'fonts/fonts.css', embed: ['woff', 'ttf'] // or false | true | woff | ttf }, files: [{ src: ['/fonts/*.{otf,ttf}'], dest: 'app/fonts' }] }
... gives us /fonts/Arial.otf and /fonts/Helvetica.ttf
this will lead to app/fonts/Arial/Arial.(eot, svg, ...) app/fonts/Helvetica/Helvetica.(eot, svg, ...)
hope u like it, or can use parts of it :)
regards iham