lasso-js / lasso

Advanced JavaScript module bundler, asset pipeline and optimizer
582 stars 75 forks source link

CacheKey reads filename first instead of pageName. #200

Open darkwebdev opened 7 years ago

darkwebdev commented 7 years ago

Documentation states: cacheKey (String) - A unique String to use for cache reads and writes. Defaults to name.

Code disagrees:

if (!cacheKey) {
        cacheKey = input.filename || pageName; // Use the filename of the template as the cache key
}

I think cacheKey = pageName || input.filename; would make more sense.