sveltejs / sapper

The next small thing in web development, powered by Svelte
https://sapper.svelte.dev
MIT License
7.01k stars 435 forks source link

javacript:history.back() is not a valid href attribute (lie!) #1736

Closed mikeoptics closed 3 years ago

mikeoptics commented 3 years ago

Describe the bug <a href="javascript:history.back()" class="underline">homepage</a> causes a console error: A11y: 'javascript:history.back()' is not a valid href attribute

But it is valid as its used to go back.

To Reproduce See Here

Expected behavior No error.

Information about your Sapper Installation:

Not relevant as it can be reproduced in REPL

Severity Not even slightly

Additional context Not just sapper but svelte too.

Conduitry commented 3 years ago

This was specifically added in https://github.com/sveltejs/svelte/pull/4733. That's not to say this won't be reconsidered, but at one point this was considered a feature and not a bug.

mikeoptics commented 3 years ago

How ironic. I get it though and Il try using a11y ignore.