Skip to content

Commit f3d75fc

Browse files
committed
chore!: simplified building process as no bundling is needed
Instead of using a bundler this library can rather just use the Typescript Compiler. It does not bundle anything and just needs to be transpiled. This is slightly breaking as we only emit the mjs files, this should work with all apps, but better safe than sorry. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
1 parent 1d7ab63 commit f3d75fc

6 files changed

Lines changed: 179 additions & 2591 deletions

File tree

lib/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* @throws if the key can't be found
1111
*/
1212
export function loadState<T>(app: string, key: string, fallback?: T): T {
13-
const elem = <HTMLInputElement>document.querySelector(`#initial-state-${app}-${key}`)
13+
const elem = document.querySelector<HTMLInputElement>(`#initial-state-${app}-${key}`)
1414
if (elem === null) {
1515
if (fallback !== undefined) {
1616
return fallback

0 commit comments

Comments
 (0)