javascript:
urls is not recommended JS-0087 38 $replyCounter," ",
39 $("<a/>").prop({
40 id: `unwatch${thread.id}`,
41 href: "javascript:;", 42 title: `Unwatch thread #${thread.id}`
43 }).on("click", () => {
44 unwatchThread(thread.id, thread.board);
185 }).insertAfter($fileInfo);
186
187 $fileInfo.append($("<a />")
188 .prop("href", "javascript:;").on("click", function() {189 $video.remove();
190 $thumb.show();
191 this.remove();
24 this.title = title;
25 this.buttonAction = action;
26 this.button = $<HTMLLinkElement>("<a/>").prop({
27 "href": "javascript:;",28 "class": "dropdown-button",
29 "id": title.toLowerCase()
30 }).text(title + "▼");
61 }).val(val);
62
63 const $form = $("<form/>").prop({
64 "action": "javascript:;", 65 "autocomplete": "off"
66 }).append(
67 $("<b/>").text(title),
Using javascript: URLs
is considered by some as a form of eval
.
Code passed in javascript: URLs
has to be parsed and evaluated by the browser in the same way that eval
is processed.
location.href = "javascript:void(0)";
location.href = "https://deepsource.io"