This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
FROM node:18.16.0 | |
ENV APP_ROOT /web | |
WORKDIR ${APP_ROOT} | |
ADD . ${APP_ROOT} | |
RUN npm ci | |
RUN npm run build |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* eslint-disable no-var,no-console */ | |
// detect unused CSS selectors | |
(function() { | |
var parsedRules = parseCssRules(); | |
console.log('Parsed CSS rules:', parsedRules); | |
detectDuplicateSelectors(parsedRules); | |
var selectorsToTrack = getSelectorsToTrack(parsedRules); | |
window.selectorStats = { unused: [], added: [], removed: [] }; | |
console.log('Tracking style usage (inspect window.selectorStats for details)...'); |