tweaselORG / appstraction

An abstraction layer for common instrumentation functions (e.g. installing and starting apps, setting preferences, etc.) on Android and iOS.
MIT License
6 stars 1 forks source link

Towards tweaselORG/cyanoacrylate#50: Print version into file to export #136

Closed zner0L closed 2 months ago

zner0L commented 2 months ago

I tested that CLI builds correctly with this shim in place.

baltpeter commented 2 months ago

I tested that CLI builds correctly with this shim in place.

But without any changes to CA, you're relying on the fact that Parcel inlines the package.json into the build for fetching CA's own version. If you don't also implement the shim into CA and rely on Parcel behaviour, you could just as well directly import and export from package.json here as well. :D

I'm not certain but we have already spent way too much time pondering this, so my vote is to have the shim both here and in CA to have as little reliance on bundler-specific behaviour as possible.

zner0L commented 2 months ago

But without any changes to CA, you're relying on the fact that Parcel inlines the package.json into the build for fetching CA's own version. If you don't also implement the shim into CA and rely on Parcel behaviour, you could just as well directly import and export from package.json here as well. :D

I tested the shim in both, I just didn’t open a PR, because I wanted to await your verdict here.