Skip to main content
32 votes

How is localStorage different from indexedDB?

@yannis answer is excellent. Just want to add a couple of things. In a few situations, like Service Workers, you cannot use blocking code, hence, you cannot use localStorage, and must use something ...
user949300's user avatar
  • 8,959
16 votes

How is localStorage different from indexedDB?

For me, I found that I can store blobs in IndexedDB while in localStorage I can store strings only. It is mean that IndexdDB is better for binary data like images, audio, video. Yes we can store ...
Vitaly Zdanevich's user avatar
9 votes
Accepted

Are tables inside tables a good idea in the right circumstance

Semantic HTML is about accurately describing the semantic structure of your document. If your document contains tabular data, then use a table. If your document contains tabular data which is itself ...
Jörg W Mittag's user avatar
8 votes

How can a html 5 game made licensed?

The usual solution is to put part of your game logic on a server somewhere and have your game communicate with it using AJAX or similar. In the server code you can check for license keys. In short, ...
Dan Pichelman's user avatar
6 votes

HTML5 localStorage and encrypted sensitive data

I'm looking for a way to have a website remember sensitive data, but without actually storing it server side. Use the server to store encrypted data, there is no reason to use localStorage. It is ...
Yeti's user avatar
  • 161
6 votes

can two web browser tabs be distinguished in a single-page application?

Session storage is tab specific (i.e. not shared across tabs). So you can check session storage for a given key value, create it if it doesn't exist, and include it in any requests you send to your ...
Jeff Lambert's user avatar
4 votes

synchronize HTML5 or JavaScript video to realtime?

Anytime you need to synchronize devices, you want one central controller instructing the devices what to do. This is just as true for mobile phones playing a video as it is the lights. I know one ...
Greg Burghardt's user avatar
4 votes

Why was Google Maps built using canvas? If it was built today, would it have rather used react/angular? Why (not)?

Any map based application will use Canvas, SVG or WebGL for actually drawing the map and it is orthogonal to using Angular or even page being SPA at all. Look at frameworks like https://openlayers.org/...
user158037's user avatar
3 votes
Accepted

What are the points of apps like Sketch and Photoshop when it comes to Web Development?

Web design consists of two aspects: designing a site, and implementing it. You are used doing both together, but it can often be sensible to separate them. For example, you might use a wireframe to ...
amon's user avatar
  • 136k
3 votes

Prefixing a number with + on html inputs

That depends on: The purpose of the input field. What an User expect the page. (User Experience standpoint) Lets discuss an example: For an e-shop page does not make sense to deal with negative ...
linuxunil's user avatar
  • 1,461
3 votes

Are there standards for handling card swipers in applications?

Not really, no. At least, not outside of the fact that there are three tracks to read from, and each has a maximum number of bytes they can hold. While there are standards that are followed, it's ...
Cypher's user avatar
  • 124
3 votes

Why is Web SQL database deprecated?

Just posting to let you know that just because WebSQL is deprecated/removed/unsupported in all the crappy browsers, you don't need to use IndexedDb. You can use SQLite via WebAssembly or JS-...
Quandary's user avatar
  • 403
2 votes

System architecture design advice

You might want to think about creating a Progressive Web App(PWA). It is a web page that has some functionality of an app when it comes to limited to now connectivity. You can run it on a desktop ...
DFord's user avatar
  • 1,250
2 votes
Accepted

Using the symbol ⎋ to denote any "escape" in Javascript, CSS, HTML etc

The name of the escape key and the phrase "escape character" are certainly linked, but I think you are stretching the definition to cover your use case. The "escape" key on keyboards is so called ...
IMSoP's user avatar
  • 5,927
2 votes

Using the symbol ⎋ to denote any "escape" in Javascript, CSS, HTML etc

A keyboard provides symbols. It is up to the software running on the computer to interpret them and respond with an action. The original intent of the Escape key is basically the same as the purpose ...
Martin Maat's user avatar
  • 18.6k
2 votes
Accepted

can two web browser tabs be distinguished in a single-page application?

You may create a unique ID (for example a UUID) at the client or let the server create it (and send it to the client at some occasion). Each request at which the server needs to discern the ...
Hero Wanders's user avatar
  • 1,067
1 vote

Using the symbol ⎋ to denote any "escape" in Javascript, CSS, HTML etc

Re-thinking my approach (included for the sake of completeness): After reflecting on @Bart van Ingen Schenau's comment: This is the first time I encountered the ⎋ symbol in my forty-odd years. and ...
Rounin's user avatar
  • 285
1 vote

can two web browser tabs be distinguished in a single-page application?

Scopes (lifetimes) Request scope all info is give as request parameters Session scope a session is maintained, probably by cookie Application scope (irrelevant) info is maintained globally For tabs ...
Joop Eggen's user avatar
  • 2,541
1 vote
Accepted

Storing session state in browser's local storage

Almost everything is a balancing act between performance, usability, maintainability. That said... What's the difference between storing session state on the client versus the server? Where ...
TZHX's user avatar
  • 5,072
1 vote

Best practices for positioning elements in an HTML-based game

It'd be nice if this used some kind of grid-based system so that it would automatically scale to arbitrary window sizes without the program manually calculating pixel widths and so forth. Tetris ...
Rounin's user avatar
  • 285
1 vote

Direction for Token Authentication Scheme in C#

Ok so that's basically a session token. Apart for your 'app wide dictionary' which will eat memory and crash your server at some level of users. The problem with your scheme is how to you integrate ...
Ewan's user avatar
  • 81.9k
1 vote

Is there a way to use html5 custom elements without javascript?

Unfortunately, custom elements were not designed to be created with html-only syntax1. They were created with the idea to change the DOM on the fly and add your own elements by javascript only.
Jiehong's user avatar
  • 11
1 vote

Is it a good idea to use width and height properties with the < td > tag?

You can use Mediaquery in css,using media query you can specify condition for displaying view in particular display size. A media query is a logical expression that is either true or false. A media ...
AjayGohil's user avatar
  • 251
1 vote

Is it a good idea to use width and height properties with the < td > tag?

According to me, It is not a good practice for the perspective of responsiveness of the web page. When you will downgrade the size of the device it may not look perfect as of now. So, better you ...
Ishan Shah's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible