felixhayashi / TW5-TiddlyMap

Map drawing and topic visualization for your wiki
http://tiddlymap.org
BSD 2-Clause "Simplified" License
845 stars 127 forks source link

Sourcemap #419

Closed flibbles closed 2 years ago

flibbles commented 2 years ago

This removes the sourcemapping out of the build. Why? Because no one is using it, and the sourcemap tags inside all the javascript files are causing a bunch of warnings to pop up whenever you open the developer tools.

But why scrap the source mapping feature? Because only works if you are using a standalone TiddlyWiki, opened locally, with the "map" directory existing in the same directory as the TiddlyWiki file. The only person who has this setup is you, Felix. No one else.

Besides, now that TW-Uglify is out, it manages sourcemapping in a way that might actually be useful to end users. It also takes care of uglifying far better and more cleanly than gulp can, but I won't get into that right now.

flibbles commented 2 years ago

See #414 for a build of TiddlyMap which includes this improvement.

felixhayashi commented 2 years ago

Hey @flibbles, many thanks for your valuable contributions!

My day jobs make it nearly impossible to maintain this project (which includes merging PRs) at the moment and in the near future. I hope you don't mind that I've therefore added you as collaborateur to this project to enable you to merge changes into the project.

The whole build process is a bit complicated and unfortunately TiddlyMap is still depending on the "legacy" version of the visjs project but maybe it can be upgraded in the future.

If you need collaborateur-access to other related repos, let me know.

flibbles commented 2 years ago

Understood. Not sure how much I'll be actively contributing either. Most of my PRs are personal grievances, but I am capable of making builds, so maybe I'll occasionally push out fix or updates.

Glad to know you're alive.

flibbles commented 2 years ago

@felixhayashi, But out of question, how much leeway do I have? If I had infinite free time...

Again, these are just ideas I'm having now that I'm thinking about it, and probably won't get to any of it. But I want to make sure I wouldn't be stepping over any boundaries if your intention of giving me control was just to push my few fixes.

felixhayashi commented 2 years ago

Thanks for your mindful comments and for asking about what can be changed. All points you mentioned sound good to me. Feel free to add any changes/fixes/improvements to both the source code and the build process. You can just go ahead, no need to ask for confirmation (unless you need some feedback from my side).

Thanks!

Just be careful to test everything before each release :pray: Some parts of the code are heavily entangled and may changes may cause unexpected sideeffects :scream:

Glad to know you're alive.

Of course! :laughing:

joshuafontany commented 2 years ago

@flibbles was able to fix the TW5 Boot code sourceMappingURL recently, by pointing to the system tiddler title containing the code transcluded as the boot section in the HTML document.

https://github.com/Jermolene/TiddlyWiki5/pull/6381

I'd love to see this possible with other plugins. @jermolene, @flibbles Any ideas on this?

flibbles commented 2 years ago

That was specifically for sourceURL, not sourceMappingURL. sourceURL just indicated what name your browser should use if you debug that chunk of code. It won't tie to anything else. All tiddlywiki code, core and plugins alike, will benefit from sourceURL. That PR was just so it applied to boot code too.

SourceMappingURL is mapping a given chunk of javascript to an uncompressed version which your browser may request from the server if you open its debug panel. TiddlyWiki has no mechanism for it, and doesn't need it, since it doesn't compress. TW-Uglify handles sourcemapping though, which is a plugin I wrote, but that's all independent of TW.

joshuafontany commented 2 years ago

@flibbles Very well explained, mahalo (thanks)!