Munter / subfont

Command line tool to optimize your webfont loading. Aggressive subsetting based on your font use, self-hosting of Google fonts and preloading
MIT License
1.56k stars 29 forks source link

Add directly used dependency #98

Closed palindrom615 closed 4 years ago

palindrom615 commented 4 years ago

bluebird, lines-and-columns, lodash, memoizesync, postcss, specificity is directly used in this repo but is not in the package.json. This causes error when using sub font with yarn.

> rg '\b(bluebird|lines-and-columns|lodash|memoizesync|postcss|specificity)\b'

lib/subsetLocalFont.js
17:const Promise = require('bluebird');

lib/getCssRulesByProperty.js
1:const specificity = require('specificity');
2:const postcss = require('postcss');
43:  const parseTree = postcss.parse(cssSource);
81:        // Split up combined selectors as they might have different specificity
82:        specificity
125:          // Split up combined selectors as they might have different specificity
126:          specificity
154:        // Split up combined selectors as they might have different specificity
155:        specificity
189:        // Split up combined selectors as they might have different specificity
190:        specificity
227:        specificity

lib/subsetFonts.js
1:const _ = require('lodash');
2:const Promise = require('bluebird');
3:const memoizeSync = require('memoizesync');
21:const LinesAndColumns = require('lines-and-columns').default;

adding those dependencies might fix the problems

coveralls commented 4 years ago

Pull Request Test Coverage Report for Build 341


Totals Coverage Status
Change from base Build 334: 0.0%
Covered Lines: 993
Relevant Lines: 1063

💛 - Coveralls
papandreou commented 4 years ago

Thanks! Released in 5.0.3.