Fix saving feature

This commit is contained in:
Sofía Aritz 2023-03-28 18:50:55 +02:00
parent 7074587114
commit 051f91c025

View file

@ -3,7 +3,10 @@ export function save_file(input) {
} }
export function load_file() { export function load_file() {
localStorage.getItem("last_item") let item = localStorage.getItem("last_item")
if (item.length > 0) {
return item
}
} }
export function save_style(style) { export function save_style(style) {
@ -11,5 +14,8 @@ export function save_style(style) {
} }
export function load_style() { export function load_style() {
localStorage.getItem("last_style") let item = localStorage.getItem("last_style")
if (item.length > 0) {
return item
}
} }