< Return to Video

11.2: Bookmarklets - Programming with Text

  • 0:00 - 0:03
    Hello. This is a video tutorial where I'm
  • 0:03 - 0:05
    going to show you how to make a very
  • 0:05 - 0:08
    simple, basic bookmarklet. And this is
  • 0:08 - 0:10
    really a warm-up. My goal here in the
  • 0:10 - 0:12
    next video and the video after that and
  • 0:12 - 0:13
    the video after that is to start looking
  • 0:13 - 0:15
    at Chrome extensions. Chrome extensions
  • 0:15 - 0:18
    are a much more powerful way to affect
  • 0:18 - 0:20
    the browsing experience as a whole and
  • 0:20 - 0:24
    actually the interface elements and all
  • 0:24 - 0:24
    sorts of stuff
  • 0:24 - 0:26
    in the Chrome browser. But a bookmarklet
  • 0:26 - 0:29
    is a really quick and easy way to add a
  • 0:29 - 0:31
    button that's like a bookmark that
  • 0:31 - 0:32
    triggers some code that changes your
  • 0:32 - 0:34
    browsing experience. So let's look at how
  • 0:34 - 0:34
    that works.
  • 0:34 - 0:39
    So before I get to that, I'm gonna leave
  • 0:39 - 0:42
    it es5 which is – and not use some of the
  • 0:42 - 0:44
    fancier newer JavaScript syntax just to
  • 0:44 - 0:46
    sort of demonstrate the simplicity of
  • 0:46 - 0:49
    the idea. But I I'm sure that it will get
  • 0:49 - 0:50
    people watching who will help suggest
  • 0:50 - 0:53
    fancier ways to write the same code, and
  • 0:53 - 0:54
    I look forward to including that in the
  • 0:54 - 0:56
    supplemental materials that'll
  • 0:56 - 0:56
    be linked from this video's description.
  • 0:56 - 1:00
    So if you've ever made a function in
  • 1:00 - 1:02
    JavaScript, you might have done this
  • 1:02 - 1:08
    function. You know. Hello. Curly bracket
  • 1:08 - 1:10
    curly – no parentheses, parentheses, curly
  • 1:10 - 1:12
    bracket, curly bracket. If I want to
  • 1:12 - 1:16
    execute this function – I want to run that
  • 1:16 - 1:18
    function – I would just say hello with the
  • 1:18 - 1:20
    parentheses. That means execute this
  • 1:20 - 1:23
    function. So now you are probably aware –
  • 1:23 - 1:26
    I'm looking for my eraser – here it is. You
  • 1:26 - 1:29
    are probably aware that in JavaScript,
  • 1:29 - 1:33
    functions could be anonymous, meaning
  • 1:33 - 1:34
    they don't have to have a name. And it
  • 1:34 - 1:40
    can just look like this. But then how do
  • 1:40 - 1:42
    you execute the function? So typically,
  • 1:42 - 1:44
    you might write an anonymous function
  • 1:44 - 1:45
    because you're passing it in somewhere
  • 1:45 - 1:46
    as a callback, and somewhere else, it's
  • 1:46 - 1:48
    gonna get a reference to it, and call it
  • 1:48 - 1:50
    somewhere. But in the case of a
  • 1:50 - 1:52
    bookmarklet, what a bookmarklet actually
  • 1:52 - 1:55
    is it's a JavaScript function that, when
  • 1:55 - 1:58
    you press the button, it runs. And so a
  • 1:58 - 2:00
    funny thing that you can do – If this is
  • 2:00 - 2:02
    the entire, right, remember? If this was
  • 2:02 - 2:05
    named, hello, then I could execute the
  • 2:05 - 2:07
    function with the name and these two
  • 2:07 - 2:10
    parentheses. But I can actually just execute
  • 2:10 - 2:11
    the function by putting the two
  • 2:11 - 2:13
    parentheses there. So this is like an
  • 2:13 - 2:14
    anonymous
  • 2:14 - 2:16
    self-executing function. Again I think
  • 2:16 - 2:18
    that's right. There's some probably more
  • 2:18 - 2:20
    appropriate technical term for it. So
  • 2:20 - 2:22
    this is actually – So, what a bookmarklet
  • 2:22 - 2:24
    actually is – and if I just put something
  • 2:24 - 2:28
    like console.log or alert, maybe
  • 2:28 - 2:29
    alert will be a good, I think I never – I
  • 2:29 - 2:31
    have this like mission in life to never
  • 2:31 - 2:33
    ever use a JavaScript alert, and I'm
  • 2:33 - 2:36
    gonna, somehow I'm gonna do that. But I'm
  • 2:36 - 2:38
    gonna break that mission – that's it – right
  • 2:38 - 2:40
    now. So I could say alert("hello").
  • 2:40 - 2:43
    So if this were the code for my
  • 2:43 - 2:45
    bookmarklet, whenever the user presses
  • 2:45 - 2:47
    the button or goes to that quote-unquote
  • 2:47 - 2:52
    bookmark, this code is gonna execute. So
  • 2:52 - 2:54
    this begs the question – This is a very
  • 2:54 - 2:56
    simple idea. And now it's up
  • 2:56 - 2:58
    to you. Like, well what do you put in here? You
  • 2:58 - 3:00
    can read – This is where you can start
  • 3:00 - 3:01
    parsing and looking at what's on the
  • 3:01 - 3:03
    webpage and changing it in real time
  • 3:03 - 3:06
    with JavaScript. But the question is,
  • 3:06 - 3:08
    "Where does this code go?" So now let's look
  • 3:08 - 3:10
    at that. All right. So you might be aware
  • 3:10 - 3:13
    that if you go – so if you go to a URL – and
  • 3:13 - 3:15
    this, you don't really see. Chrome, by
  • 3:15 - 3:17
    the way, is hiding the fact that this is
  • 3:17 - 3:21
    http://. So I could go to the
  • 3:21 - 3:24
    URL by saying http [inaudible], I'm saying I
  • 3:24 - 3:26
    want to make a hypertext transfer
  • 3:26 - 3:28
    protocol get request to this URL. But I
  • 3:28 - 3:31
    can also, in the browser, look at things
  • 3:31 - 3:36
    that are like files on the computer. So I
  • 3:36 - 3:38
    can open up index.html, and you can
  • 3:38 - 3:41
    see, "Oh look! Now I'm going to the file://,
  • 3:41 - 3:44
    but I can actually –
  • 3:44 - 3:45
    there is – and there's actually like a
  • 3:45 - 3:49
    data path where I can do base64
  • 3:49 - 3:50
    encoded images. There's all sorts of
  • 3:50 - 3:52
    different kinds of paths that the
  • 3:52 - 3:54
    address bar will accept. One of them
  • 3:54 - 4:00
    happens to be JavaScript. Let's – Dare I
  • 4:00 - 4:04
    try to do this? Function – Oh, I am
  • 4:04 - 4:06
    remembering something that I'm also
  • 4:06 - 4:07
    being told in the chat. I made a little
  • 4:07 - 4:11
    mistake here, which is that in order for
  • 4:11 - 4:12
    you to execute this function the way
  • 4:12 - 4:15
    that I've described here, you actually
  • 4:15 - 4:17
    have to also enclose the entire nameless
  • 4:17 - 4:19
    or anonymous function in parenthesis
  • 4:19 - 4:22
    itself. So otherwise, it's unclear
  • 4:22 - 4:25
    I guess to the interpreter like what
  • 4:25 - 4:26
    this actually matches up with.
  • 4:26 - 4:28
    So this is execute the function that's
  • 4:28 - 4:30
    inside these parentheses. I'm pretty sure
  • 4:30 - 4:34
    that's required. So. Now let's come back
  • 4:34 - 4:36
    here. So the reason why I thought of that is because
  • 4:36 - 4:38
    now, I'm going to actually just type
  • 4:38 - 4:41
    that code in right here in the address
  • 4:41 - 4:44
    bar. Function – It's gonna be really hard.
  • 4:44 - 4:52
    Function, curly bracket, alert hello,
  • 4:52 - 4:54
    semicolon, close curly bracket, close
  • 4:54 - 4:56
    parenthesis, parenthesis, parenthesis. So
  • 4:56 - 4:59
    this is me saying, "I want to go to this
  • 4:59 - 5:02
    URL. It's JavaScript://.
  • 5:02 - 5:03
    Actually I don't think you need the slash
  • 5:03 - 5:06
    slash if I'm thinking about this. I think
  • 5:06 - 5:09
    it's just JavaScript:, and then this
  • 5:09 - 5:11
    code, which is a self-executing anonymous
  • 5:11 - 5:14
    function. So I'm gonna zoom back out here.
  • 5:14 - 5:17
    And I'm going to now hit enter as if I'm
  • 5:17 - 5:20
    loading this web page. And I get this
  • 5:20 - 5:21
    alert. The page says, "Hello."
  • 5:21 - 5:24
    So that's actually what a
  • 5:24 - 5:26
    bookmarklet is. And I wish I had
  • 5:26 - 5:29
    copy-pasted that, because now, all I need to do
  • 5:29 - 5:32
    is I can say – I can have a paragraph and
  • 5:32 - 5:37
    I can say, "Hey, this is –
  • 5:37 - 5:42
    I could say a href = bookmarklet.
  • 5:42 - 5:45
    All right. So we'll take a look at this.
  • 5:45 - 5:47
    Now we can see this here. Now if I click
  • 5:47 - 5:50
    on this, nothing happens. So what can go
  • 5:50 - 5:55
    in a – What can be the h ref to an a tag?
  • 5:55 - 6:00
    It could be a URL? It could be –
  • 6:00 - 6:02
    It could be lots of things. One of the things that
  • 6:02 - 6:05
    it can be is actual JavaScript code. So for
  • 6:05 - 6:08
    example, that same thing that I typed,
  • 6:08 - 6:12
    JavaScript: function – Oh I need to
  • 6:12 - 6:14
    put parentheses around the function.
  • 6:14 - 6:22
    function a parenthesis, a curly bracket, alert
  • 6:22 - 6:25
    hello,
  • 6:25 - 6:29
    close quote, close parenthesis, close
  • 6:29 - 6:31
    curly bracket, close parentheses, execute.
  • 6:31 - 6:35
    So now let's try refreshing this page
  • 6:35 - 6:38
    and now whenever I click on that, it runs
  • 6:38 - 6:40
    that JavaScript code.
  • 6:40 - 6:44
    Now guess what. If I wanted to bookmark a
  • 6:44 - 6:47
    URL, all the whole thing, like, if I – Like
  • 6:47 - 6:49
    here, I have a bookmark up here to the
  • 6:49 - 6:51
    rainbow topics github repository. If I
  • 6:51 - 6:54
    click edit, all this is is a name for
  • 6:54 - 6:56
    this particular URL. A bookmarklet is
  • 6:56 - 7:00
    just a named set of JavaScript code. So I
  • 7:00 - 7:05
    can now say, I can now – If actually
  • 7:05 - 7:07
    what – I could create it. But I
  • 7:07 - 7:09
    can't really just drag this up here and
  • 7:09 - 7:10
    you can see – look at that. Now I have this
  • 7:10 - 7:13
    here. And every time I click on it, I
  • 7:13 - 7:18
    get that alert. Click. Alert. Click. Alert.
  • 7:18 - 7:22
    And if I go edit, we can see this is just
  • 7:22 - 7:26
    this – Now it's URL encoded. It did that for
  • 7:26 - 7:30
    me because a quote is not a valid
  • 7:30 - 7:35
    character in a URL. So this has
  • 7:35 - 7:37
    been URL encoded meaning %27. You'll
  • 7:37 - 7:40
    often see like % 20. That means space %
  • 7:40 - 7:42
    27 currently means single quote, I think.
  • 7:42 - 7:44
    So you can see – you can write it this way.
  • 7:44 - 7:47
    Now – so in a way, we're done. Yay. We made a
  • 7:47 - 7:50
    bookmarklet. But we haven't really done
  • 7:50 - 7:52
    anything yet. Like, here's the thing. Is
  • 7:52 - 7:55
    this really sustainable. Is this the
  • 7:55 - 7:57
    thing like, "Oh my goodness. And how am I
  • 7:57 - 7:58
    going to send – What if I want to do
  • 7:58 - 7:59
    something really elaborate. I want to
  • 7:59 - 8:02
    crawl – I want to look at all the content
  • 8:02 - 8:04
    on that web page and I want to find all
  • 8:04 - 8:05
    the paragraph elements and I want to
  • 8:05 - 8:09
    look anytime the word puppy is in there,
  • 8:09 - 8:10
    I want to change the word puppy to
  • 8:10 - 8:12
    kitten. So it's a bookmarklet that
  • 8:12 - 8:14
    changes puppies to kittens – or swap
  • 8:14 - 8:16
    images out, or change the background
  • 8:16 - 8:19
    color of every web page to a random
  • 8:19 - 8:20
    color. All these things are possible. But
  • 8:20 - 8:23
    working with kind of trying to write the
  • 8:23 - 8:25
    code in here is going to be so
  • 8:25 - 8:28
    incredibly awkward. Like, how am I gonna
  • 8:28 - 8:30
    really develop. Because I can't really
  • 8:30 - 8:32
    have line breaks or spaces very easily
  • 8:32 - 8:35
    here. So there is a strategy that is used
  • 8:35 - 8:38
    quite often. So the next step that I want
  • 8:38 - 8:41
    to show you is how could I write all of
  • 8:41 - 8:43
    my bookmarklet code in a separate
  • 8:43 - 8:48
    JavaScript file, and then simply point to
  • 8:48 - 8:50
    it from here? So in other words, what I
  • 8:50 - 8:54
    want to say is new file,
  • 8:54 - 9:00
    I'm just gonna call it bookmarklet.js.
  • 9:00 - 9:02
    And then what I want to do is I want to
  • 9:02 - 9:04
    be able to write the bookmarklet in a
  • 9:04 - 9:05
    way that's much easier for me to
  • 9:05 - 9:09
    follow and debug. So, for example,
  • 9:09 - 9:13
    something that I might do is I might say
  • 9:13 - 9:16
    console.log, bookmarklet
  • 9:16 - 9:19
    starting. And then I might say – and now I
  • 9:19 - 9:21
    don't have access to – There is a way to
  • 9:21 - 9:24
    gain access to JavaScript libraries, like
  • 9:24 - 9:27
    I could have jQuery or p5 be a part of
  • 9:27 - 9:28
    what I'm doing. But I'm gonna just do
  • 9:28 - 9:30
    stuff with native JavaScript. So I could
  • 9:30 - 9:33
    say, for example: let p –
  • 9:33 - 9:40
    paragraphs = document.get
  • 9:40 - 9:45
    elementsByTagName, p, and then I
  • 9:45 - 9:47
    could say for
  • 9:49 - 9:54
    let i = 0, i < paragraphs.length,
  • 9:54 - 9:58
    i++, and I could say
  • 9:58 - 10:03
    paragraphs, index i.innerHtml = ...
  • 10:03 - 10:04
    So this is me like kind of doing a
  • 10:04 - 10:06
    little version of The Deletionist,
  • 10:06 - 10:08
    or Wordless Web. Like, we find all the
  • 10:08 - 10:09
    paragraphs on the page and just set
  • 10:09 - 10:11
    their inner HTML to nothing. Or I could
  • 10:11 - 10:14
    say set their inner HTML to kitten.
  • 10:14 - 10:17
    So this, now, if I wanted to, I could put
  • 10:17 - 10:19
    all of this into that JavaScript URL, and
  • 10:19 - 10:23
    I could remove all of the – I could
  • 10:23 - 10:24
    remove all the white space and probably
  • 10:24 - 10:26
    make it work. But what I could do that's
  • 10:26 - 10:29
    a little bit easier is – and I'm gonna I'm
  • 10:29 - 10:33
    gonna just type this out on this in this
  • 10:33 - 10:36
    text document for a second.
  • 10:36 - 10:40
    Down here, I could actually say, all
  • 10:40 - 10:45
    right – So this is kind of the – and I could
  • 10:45 - 10:47
    write this anonymous function, and
  • 10:47 - 10:51
    then what I can do is one of the things
  • 10:51 - 10:54
    you can do in JavaScript is add elements
  • 10:54 - 10:56
    to the web page. And so the element that
  • 10:56 - 10:58
    I want to add is a script. So I'm going
  • 10:58 - 11:03
    to say let script = document.
  • 11:03 - 11:06
    createElement script.
  • 11:06 - 11:10
    And then what I want to do is I want to
  • 11:10 - 11:13
    change the source – script.source
  • 11:13 - 11:22
    equal to bookmarklet.js. So I want the
  • 11:22 - 11:25
    source to point to this other JavaScript
  • 11:25 - 11:28
    file, and then I want to say
  • 11:28 - 11:33
    document.body.appendchild script. So in
  • 11:33 - 11:34
    other words, this is kind of some
  • 11:34 - 11:37
    boilerplate code that can basically say,
  • 11:37 - 11:41
    "Point to a different
  • 11:41 - 11:43
    javascript file that's gonna have all
  • 11:43 - 11:45
    this other stuff and tons and tons of
  • 11:45 - 11:48
    code, and then just load that and execute
  • 11:48 - 11:51
    that code whenever the bookmarklet is
  • 11:51 - 11:54
    triggered. So this is actually what I
  • 11:54 - 11:57
    want. Did I get this right? And hopefully, I
  • 11:57 - 12:00
    got this right. This is what I want to go
  • 12:00 - 12:04
    in here. And this is going to be a little
  • 12:04 - 12:06
    tricky to make happen. Actually what I'm
  • 12:06 - 12:09
    gonna do – I'm gonna do this here – is now
  • 12:09 - 12:10
    what I'm going to do is I'm going to
  • 12:10 - 12:14
    just put this all on one line. There
  • 12:14 - 12:16
    might be a way for it to account for
  • 12:16 - 12:19
    line breaks and stuff. So I'm gonna take
  • 12:19 - 12:22
    this now and I'm gonna put it in here
  • 12:22 - 12:25
    [hums a note]
  • 12:25 - 12:29
    Let's see – Is this is really gonna work? I
  • 12:29 - 12:32
    didn't close the paragraph tag. So let's
  • 12:32 - 12:35
    see what happens here. So I am now going
  • 12:35 - 12:40
    to refresh this page. I'm going to delete
  • 12:40 - 12:42
    this one up here. I don't know if you can see that. I
  • 12:42 - 12:46
    am going to – I'm just gonna like click
  • 12:46 - 12:51
    this. Okay. Error 404. File not Found. So
  • 12:51 - 12:53
    I think there's a – Okay. So there's a
  • 12:53 - 12:55
    little bit of an issue here, which is
  • 12:55 - 12:58
    that – and I'm gonna get to this. You
  • 12:58 - 12:59
    actually need to host your JavaScript
  • 12:59 - 13:01
    file somewhere, and I have one that I
  • 13:01 - 13:03
    already made and hosted somewhere. Let's
  • 13:03 - 13:05
    see if I can get the one that I – So this
  • 13:05 - 13:06
    won't really work in a sustainable
  • 13:06 - 13:09
    way. But what I can do – I wonder if it
  • 13:09 - 13:11
    doesn't like the whitespace either. But I
  • 13:11 - 13:14
    think more likely, right, what I need to
  • 13:14 - 13:18
    do is just say "this". Because what I want
  • 13:18 - 13:20
    to do – Let's just make sure this is the
  • 13:20 - 13:20
    right
  • 13:20 - 13:24
    URL for that JavaScript code. It is.
  • 13:24 - 13:26
    There's that JavaScript code of that URL.
  • 13:26 - 13:31
    So that should allow it to point to
  • 13:31 - 13:33
    the actual URL where that JavaScript
  • 13:33 - 13:38
    code is hosted. Now what I'm gonna do is
  • 13:38 - 13:44
    click this. Arrgh! Oops. I made a really silly
  • 13:44 - 13:45
    error.
  • 13:45 - 13:46
    I completely forgot that I need to have
  • 13:46 - 13:49
    this say JavaScript at the beginning.
  • 13:49 - 13:51
    Just miscellaneous JavaScript code in
  • 13:51 - 13:55
    that URL is not gonna do any good. So
  • 13:55 - 13:57
    this has to say JavaScript. Sorry about
  • 13:57 - 13:57
    that.
  • 13:57 - 13:59
    All right. So let's try it now. I'm gonna
  • 13:59 - 14:01
    click on this bookmarklet. And it made a
  • 14:01 - 14:03
    kitten, and we see the console log.
  • 14:03 - 14:05
    Perfect. So what I could do is I can now
  • 14:05 - 14:08
    drag this up to here. I could go to like
  • 14:08 - 14:11
    my tutorial page. I'm now on my tutorial
  • 14:11 - 14:13
    page. I'm gonna scroll to the middle
  • 14:13 - 14:14
    somewhere where there's a bunch of
  • 14:14 - 14:15
    paragraphs. I'm gonna click the
  • 14:15 - 14:18
    bookmarklet. And all the paragraphs now
  • 14:18 - 14:20
    say "kitten." Yes. So, this is the basic idea
  • 14:20 - 14:23
    of making a bookmarklet. What you need to
  • 14:23 - 14:25
    do – and it's obviously a little trickier
  • 14:25 - 14:26
    than I thought – and you can see,
  • 14:26 - 14:28
    actually, I should have just copy-pasted the code from
  • 14:28 - 14:31
    my tutorial. But here it is right here.
  • 14:31 - 14:34
    I can just – Basically, all I need to do is
  • 14:34 - 14:39
    have this boilerplate code that points
  • 14:39 - 14:43
    to a JavaScript program that's hosted
  • 14:43 - 14:47
    somewhere. And then, what it does is that
  • 14:47 - 14:50
    JavaScript program does something, parses
  • 14:50 - 14:52
    the web page, changes some stuff, anything
  • 14:52 - 14:53
    is possible there. Now there's a couple
  • 14:53 - 14:55
    things I want to mention about this.
  • 14:55 - 14:58
    Browsers love love love love
  • 14:58 - 15:02
    love to cache your stuff. So if I – I don't
  • 15:02 - 15:04
    know if this is gonna
  • 15:04 - 15:05
    happen, but let's see if we can make this
  • 15:05 - 15:09
    happen. If I change this now to say puppy,
  • 15:09 - 15:14
    right, and I go back to and refresh this
  • 15:14 - 15:17
    page and click the bookmarklet, it does
  • 15:17 - 15:19
    say "puppy." So, it worked. But I've
  • 15:19 - 15:21
    definitely been in a situation where I
  • 15:21 - 15:23
    changed the code and the bookmarklet
  • 15:23 - 15:26
    didn't actually update when I
  • 15:26 - 15:29
    executed it. So a way that you can
  • 15:29 - 15:31
    get around this, I actually have it here
  • 15:31 - 15:33
    in this tutorial. So I'll just –
  • 15:33 - 15:33
  • 15:33 - 15:37
    is to add a kind of arbitrary URL argument
  • 15:37 - 15:41
    which is like the current date and time,
  • 15:41 - 15:43
    which will force – it'll make the URL
  • 15:43 - 15:45
    appear different to the page that's
  • 15:45 - 15:47
    loading the JavaScript code, and it'll
  • 15:47 - 15:49
    force it to reload. So I'm gonna leave
  • 15:49 - 15:51
    that out of adding that in. But you can –
  • 15:51 - 15:53
    When I publish the code for this example,
  • 15:53 - 15:56
    I'll include that as part of the code.
  • 15:56 - 15:59
    Now, what I've shown you so far, it
  • 15:59 - 16:01
    doesn't really do you any good.
  • 16:01 - 16:02
    At least what I'm going to do is I'm going
  • 16:02 - 16:07
    to show you this is actually a piece of
  • 16:07 - 16:08
    JavaScript code that's basically the
  • 16:08 - 16:10
    same thing that just takes all the
  • 16:10 - 16:12
    paragraphs and changes their background
  • 16:12 - 16:16
    color to some purple. So the way that you
  • 16:16 - 16:17
    really want to do this is you want to
  • 16:17 - 16:19
    host your JavaScript code somewhere
  • 16:19 - 16:22
    permanent, and then what you want is for
  • 16:22 - 16:23
    the bookmarklet
  • 16:23 - 16:27
    to reference, not like – referencing
  • 16:27 - 16:29
    localhost is no good. It's gonna work on
  • 16:29 - 16:30
    my computer. But you want to reference a
  • 16:30 - 16:33
    URL that's actually out there somewhere
  • 16:33 - 16:34
    in the cloud. The nice thing about this
  • 16:34 - 16:38
    is, as people use your bookmarklet – I mean
  • 16:38 - 16:39
    there's is a sort of security
  • 16:39 - 16:42
    question here. You can change your
  • 16:42 - 16:43
    bookmarklets code and they don't have to
  • 16:43 - 16:46
    reinstall it because the the actual code
  • 16:46 - 16:48
    that they have in the bookmarklet is
  • 16:48 - 16:49
    just pointing to another JavaScript file,
  • 16:49 - 16:51
    and that JavaScript file can be updated.
  • 16:51 - 16:53
    Ok. So maybe I'll come back and do a
  • 16:53 - 16:55
    coding challenge. So send
  • 16:55 - 16:57
    me your creative bookmarklets that change
  • 16:57 - 16:59
    images to kittens or puppies or
  • 16:59 - 17:02
    rainbows or unicorns or whatever, and
  • 17:02 - 17:03
    all sorts of, I'm sure, more creative
  • 17:03 - 17:05
    ideas than what I can think of right now,
  • 17:05 - 17:07
    but I'm gonna now move into Chrome
  • 17:07 - 17:10
    extensions. We can do – I'm gonna start by
  • 17:10 - 17:11
    making a Chrome extension that does
  • 17:11 - 17:14
    exactly the same thing, but with this
  • 17:14 - 17:16
    kind of code that alters your view of a
  • 17:16 - 17:18
    web page in a Chrome extension, there's
  • 17:18 - 17:20
    going to be a lot more possibilities of
  • 17:20 - 17:22
    what you can do beyond that, okay? So thanks
  • 17:22 - 17:23
    for watching this bookmarklet tutorial,
  • 17:23 - 17:30
    and I'll see you in the next one.
Title:
11.2: Bookmarklets - Programming with Text
Description:

more » « less
Video Language:
English
Duration:
17:36

English subtitles

Incomplete

Revisions