-
Notifications
You must be signed in to change notification settings - Fork 6
Open
Description
Copied from: scssphp/scssphp#2
Rationale:
- the Server class is getting bloated
- the Server class has too many public functions:
- compileFile() - always recompiles
- checkedCompile() - compiles scss if cache doesn't exist
- checkCachedCompile() - recompiles if necessary
- serve() - the original purpose of this class
Identified candidate cache implementations:
- never - no caching; always (re)compiles
- read - read only if cache exists; doesn't create
- once - compiles only if cache doesn't exist
- surface/shallow - recompile if main .scss file changes (note: this has no current API equivalent)
- deep - recompile if main .scss file or any of its imports changes
Technical considerations:
- bust up the Server class
- Cache/*.php implementations
- "deep" should detect changes in setVariables() and setImportPaths()
Other changes:
- make Compiler cache aware (also, see existing importCache)
- stale file detection using algorithm instead of metadata Update Server with cachedCompile() method like lessphp leafo/scssphp#321
- parse tree cache Is there a way to make the compiler more performant? leafo/scssphp#328
- register custom error handler Ability to register error handler with Server leafo/scssphp#330
- register custom input finder Manually specify file to be served leafo/scssphp#329
- option to set/override or remove comment "compiled by scssphp..." Option to remove comment "compiled by scssphp..." leafo/scssphp#477
- option to compress (gzip) output Function to get gzipped result leafo/scssphp#483
Metadata
Metadata
Assignees
Labels
No labels