-
The # INSTALL v0.0.1
$ deno install --location=<URL> <SERVER>@0.0.1/test.js
$ test
localStorage is empty
$ test
localStorage has data
# UPGRADE to v0.0.2
$ deno install -f --location=<URL> <SERVER>@0.0.2/test.js
$ test
localStorage has data Example script: // test.js
#!/usr/bin/env -S deno run
console.log(localStorage.getItem('test') || 'localStorge is empty');
localStorage.setItem('test', 'localStorage has data'); But is it possible to persist localStorage without using the Thank you. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
It's not possible, this is an intended use of *Well, more than once if we consider upgrades. Some installed programs provide an |
Beta Was this translation helpful? Give feedback.
It's not possible, this is an intended use of
--location
. It's not considered too much of a burden to specify it becausedeno install
commands are typically copy-pasted from your project README once* and it won't have to be specified by your users beyond that.*Well, more than once if we consider upgrades. Some installed programs provide an
upgrade
subcommand which does this for you, e.g. https://github.com/denoland/deployctl/blob/eb9f6f71747443b9dbd074d2c417e7e94df576be/src/subcommands/upgrade.ts.