Comments (3)
Relative paths to the src would be a better idea i guess
tested it by editing the map file.
{"version":3,"file":"explorer.js", "sources":["../explorer.js", "../explorer.list.js"] }
from grunt-jsmin-sourcemap.
While this is in agreement with the sourcemap spec, I would like to make this repo as customizable as possible. By that, I mean if someone wants to host 'project/myproject/dist' at 'aaa/aaa/aaa', they should be allowed to.
As a result, I make an attempt to make the default configuration as simple as possible.
All of that being said, I have actually had requests for similar cases in the past and solved them via the source-map native sourceRoot
property as well as a cwd
edit for users to hook onto. These should suffice for your project, I believe the following will work for your config
{
'jsmin-sourcemap': {
explorer: {
src: ['explorer.js', 'explorer.*.js'],
dest: 'dist/explorer.js',
cwd: 'project/myproject/static/js'
}
}
from grunt-jsmin-sourcemap.
Closing issue due to inactivity and lack of counter-argument to sourceRoot
+ cwd
solution. If we want a better/more proper solution, I would prefer a router
argument comparable to that found in grunt-curl.
from grunt-jsmin-sourcemap.
Related Issues (14)
- Getting Error: AssertionError: "\t" === " " HOT 6
- could add 'uglify' function to this grunt task HOT 3
- Grunt 0.4 Release HOT 1
- Please update the grunt-retro dependency HOT 3
- 'use strict' breaks source map line numbers HOT 16
- Optional source maps HOT 1
- excluse files from jsmin HOT 3
- adding source and dist files in different directories HOT 1
- Support for adding source and dist files in different directories HOT 3
- Sourcemap path should be relative to dest file HOT 1
- Sourcemaps not generated for more than 2 files HOT 3
- Look into whether the sourcemap's file should be a relative path HOT 1
- readme says destMap but its map that works HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from grunt-jsmin-sourcemap.