Workiva / wGulp

Opinionated Suite of Gulp Tasks for JavaScript and TypeScript projects.
Apache License 2.0
12 stars 9 forks source link

Allow Karma to serve .map files by default #69

Closed maxwellpeterson-wf closed 10 years ago

maxwellpeterson-wf commented 10 years ago

Fixes #68

Problem

.map files were not in the karma configuration for files that karma can serve. This causes sourcemaps not to work when running test watches in Chrome

Solution

Add the proper config for *.map files.

Testing

You can use react-tree or any TypeScript project to test.

@trentgrover-wf @evanweible-wf @charliekump-wf

FYI - @patkujawa-wf

patkujawa-wf commented 10 years ago

@maxwellpeterson-wf I tried this with wAnalytics and I don't get 404s any more for the .map files, but I think the maps point to the wrong place because I get 404s for the typescript source files now: WARN [web-server]: 404: /base/src/AnalyticsReporter.ts. Is wGulp correctly setting the location of 'base' for typescript files?

trentgrover-wf commented 10 years ago

+10

NOTE: Tested this with a sample project and found that more files need to be served up for TypeScript source maps to work both for the src and test files (for easier debugging of tests)

@patkujawa-wf does this fix the issue you mention above? @maxwellpeterson-wf can you +1 this for me?

patkujawa-wf commented 10 years ago

@trentgrover-wf yep, now I can hit breakpoints in my TS files - thanks! :+1:

maxwellpeterson-wf commented 10 years ago

+1 looks good

trentgrover-wf commented 10 years ago

@charliekump-wf ready to merge

charliekump-wf commented 10 years ago

QA Resource Approval: +1

Merging into master.