Hacker News new | past | comments | ask | show | jobs | submit login

> you'll save a ton of space in that b64, and arguably some user privacy, by trying to use workspace relative paths

That was a pattern we initially went with but it adds some complexity:

The React compiler gives absolute paths, which we can adjust to relative paths by passing in the current process' running location into our plugin. This makes the plugin API more complex. We'd also have to track the project's relative path at runtime and concat it back.

We decided the extra characters were worth it to eliminate the extra complexity. I do realize that the character number scales with the path + complexity of the project.

> JS had access to gzip (or zlib)

I haven't looked at this but will give it a try. We're doing some compression here but there's also a performance hit for compressing too much at build time.

I do think we can save space by using a different format than JSON. Even just a raw string. Something like: 'path/to/file:startTag:start:line:col:...'




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: