IPFS version - banner if the page is not current #6
Štítky
Bez milníku
Žádný projekt
Bez zpracovatelů
2 účastníků
Oznámení
Termín dokončení
Žádný termín dokončení.
Závislosti
Nejsou nastaveny žádné závislosti.
Reference: ethbrno/eb2-website#6
Načítá se…
Odkázat v novém úkolu
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
We have a situation where we can't push every release to ENS because of the fees, so we'll only throw important milestones in there.
So it can sometimes happen that an IPFS version is not updated
Here's how I would handle it:
IPFS/ENS version enhancementsna IPFS version - banner if the page is not updatedIPFS version - banner if the page is not updatedna IPFS version - banner if the page is not currentin JSON we will have a version information that will be compared between ipfs and hosted version, in case of difference we will show a banner
@tree would you add the version info or should I try?
I've already done some versioning here: https://git.gwei.cz/ethbrno/eb2-website/releases
So I just extended it and added it to package.json
Now it adds the
version
property to data.json automatically at build time:3f0633aa81
To regenerate data:
I added to write the data.json file to static as well, so now it is available directly via http:
Access to fetch at 'https://ethbrno.cz/data.json' from origin 'http://localhost:5173' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled.
It should work now, i have added:
access-control-allow-origin: *
So :) IPFS version should be updated as long as the client does not disable javascript - I used SWR pattern in the end (lame version). Needs to be tested. I am also suggesting two followups to change footer info and display warning in case of disabled javascript.