mirror of
https://github.com/searxng/searxng.git
synced 2025-08-03 10:32:21 +02:00
[mod] oscar: fix the sourcemap URL in *.min.css
Close https://github.com/searx/searx/issues/2670 Note: clean-css contains a bug: * a multiline comment or URL adds "$stdin" to the sourcemap (see src/less/logicodev/search.less) * in this case when the user opens the devtools, the browser fails to load this "https://.../$stdin" URL * it is not a problem and the error appears only when the user actively tries to debug the CSS. * seems related to https://github.com/jakubpawlowicz/clean-css/issues/593
This commit is contained in:
parent
a48ec0b4bd
commit
6bd01bf81f
15 changed files with 22 additions and 45 deletions
|
@ -1,3 +1,4 @@
|
|||
/*jshint esversion: 6 */
|
||||
module.exports = function(grunt) {
|
||||
|
||||
grunt.initConfig({
|
||||
|
@ -101,14 +102,17 @@ module.exports = function(grunt) {
|
|||
},
|
||||
production: {
|
||||
options: {
|
||||
paths: ["src/less/pointhi", "src/less/logicodev", "src/less/logicodev-dark", "less/bootstrap"],
|
||||
paths: ["src/less/pointhi", "src/less/logicodev", "src/less/logicodev-dark", "src/less/bootstrap"],
|
||||
plugins: [
|
||||
new (require('less-plugin-clean-css'))()
|
||||
],
|
||||
sourceMap: true,
|
||||
sourceMapURL: (name) => { const s = name.split('/'); return s[s.length - 1] + '.map';},
|
||||
outputSourceFiles: false,
|
||||
sourceMapRootpath: '../'
|
||||
},
|
||||
files: {
|
||||
"css/bootstrap.min.css": "src/less/bootstrap/bootstrap.less",
|
||||
"css/bootstrap.min.css": "css/bootstrap.css",
|
||||
"css/leaflet.min.css": "css/leaflet.css",
|
||||
"css/pointhi.min.css": "src/less/pointhi/oscar.less",
|
||||
"css/logicodev.min.css": "src/less/logicodev/oscar.less",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue