Share Target - HTTP 203

Поділитися
Вставка
  • Опубліковано 12 вер 2024
  • Jake demos the Share Target API, including some new bits, just landing in Chrome Canary.
    Squoosh demo: share-target--...
    Simple text demo: share-target-d...
    Simple file demo: share-target-d...
    Also, did you know we do a podcast? Yes? Well, here's some links anyway:
    developers.goo...
    itunes.apple.c...
    player.fm/seri...
    open.spotify.c...

КОМЕНТАРІ • 47

  • @mika2666
    @mika2666 5 років тому +4

    If this works with multiple files this is going to improve my app A LOT

    • @GodOfMacro
      @GodOfMacro 4 роки тому

      files is an array, so i guess it does ?

  • @FeanaroKurufinve
    @FeanaroKurufinve 5 років тому +1

    guys, we DO return on a successful POST request. many APIs serve the created object in the HTTP 201 response, some even put valuable meta info there (e. g. IDs of newly created entities). so, there's that

    • @LuLeBe
      @LuLeBe 2 роки тому

      Surely on an API but not often on a frontend site. I mean you could do the same thing (maybe creating a new item in a list then shows the detail page of that item without a redirect) but you always gotta think whether the user would expect to be able to reload that page.

  • @dkarbaev
    @dkarbaev 5 років тому +8

    Hm, I wonder if iOS would ever support this?

    • @spartanatreyu
      @spartanatreyu 5 років тому +2

      @@atilkan All browsers on iOS are Safari

    • @HarryManchanda
      @HarryManchanda 5 років тому +1

      @@spartanatreyu YUP chrome is also safari based on IOS because they don't allow much!

  • @warrenscantlebury3260
    @warrenscantlebury3260 3 роки тому

    I cant get this to work, does it simply need the web app to be added to home screen?

  • @Diamonddrake
    @Diamonddrake 4 роки тому

    You def respond to posts with content. That’s what restful web services are all about.

  • @renanlecaro
    @renanlecaro 5 років тому +11

    It's a bit cringey, but the good kind of cringey.

  • @MarcelRobitaille
    @MarcelRobitaille 5 років тому +1

    14:05 What do you mean back in the day? I use pipes daily and I know a lot of other people do too.

    • @dassurma
      @dassurma 5 років тому +6

      I use them, too. I just grabbed something from the wrong phrase bag in my head.

  • @hobbyturystaSEO
    @hobbyturystaSEO 4 роки тому

    is it possible to use squoosh with ionic 5 angular 9 firebase ml kit ?

  • @TheNewton
    @TheNewton 5 років тому

    share_target: github
    share_target: Google doc
    share_target: slack
    share_target: WordPress
    Don't understand the implications fully here but is this able to enhance workflow on any site with say a chrome extension to shuffle a workpiece between platforms?

  • @AbhishekKumar-mq1tt
    @AbhishekKumar-mq1tt 5 років тому

    Thank u for this awesome video

  • @mischmerz
    @mischmerz 5 років тому

    Here's the thing: It doesn't really work in more complex environments. First: Nobody uses inline-script anymore. So the resultingClientId may not even match if the app's script is separated from the redirected page. Second: The share message fires immediately after the the redirected page has been fetched. Again - the JavaScript responsible for receiving the message from the worker has not even been loaded. So - no - this is not a good example. Sorry guys.

  • @LarsRyeJeppesen
    @LarsRyeJeppesen 5 років тому

    This is so awesome

  • @zanehannan5306
    @zanehannan5306 5 років тому

    First thing I did on the simple file demo: give it an ogg
    Also, will this be backported to older phones, ie Nexus 6P and Nexus 5? Or is this Android 9+ (or something) only?

    • @LuLeBe
      @LuLeBe 2 роки тому +1

      I would assume any Android version with the current share API? The targets are added by Chrome, not by the OS. So some old Android 4 where the share API might have been different is not supported but newer versions should be.

  • @nicolasparada
    @nicolasparada 5 років тому

    That's cool. Very cool 😮

  • @DenisTRUFFAUT
    @DenisTRUFFAUT 5 років тому

    Wow. Love it.

  • @dikatok
    @dikatok 5 років тому

    this is pretty cool

  • @drewroyster3046
    @drewroyster3046 5 років тому +5

    Do we even need to make native apps anymore?

    • @artgreg2296
      @artgreg2296 5 років тому +3

      lol

    • @orlovsskibet
      @orlovsskibet 5 років тому +3

      Yes, we still cannot do background tracking (for sport trackers) 😢

    • @jurgentreep
      @jurgentreep 5 років тому +2

      for iOS yes ;)

    • @jakearchibald
      @jakearchibald 5 років тому

      @@orlovsskibet Check out developers.google.com/web/updates/2018/12/wakelock

  • @Santoshumnekar
    @Santoshumnekar 5 років тому

    Awesome 👍😊😊

  • @rw251
    @rw251 5 років тому

    Presumably the native apps use the mime-type filter to only display the PWA as a share target if the file to be shared matches the filter? On a related point, it's a shame that you need to use a catch all */* hack in case the browser/os doesn't understand the mime type of the file to be shared.

    • @jakearchibald
      @jakearchibald 5 років тому

      You can include extensions too. There's some discussion of this over at github.com/WICG/web-share-target/issues/74

  • @jonbikaku6133
    @jonbikaku6133 5 років тому

    Love it lol!

  • @arjunjadhav8241
    @arjunjadhav8241 2 роки тому

    Will it work on IOS???

  • @k1ngjulien_
    @k1ngjulien_ 5 років тому

    Can you do the opposite too?
    Share from a pwa to a native app?

    • @jakearchibald
      @jakearchibald 5 років тому +3

      Yep! developers.google.com/web/updates/2016/09/navigator-share. Although you can't share files yet. Folks are working on that now.

  • @XiXora
    @XiXora 5 років тому

    Theres me thinking this is more "off the cuff" and there you are getting your make up done… 🤯

  • @pdsnpsnldlqnop3330
    @pdsnpsnldlqnop3330 5 років тому

    If I have a simple page that installs as a web app can i get this to work? My simple page does a fetch to the server and it takes a URL plus a couple of options. The backend that fetch goes to only returns JSON encoded stuff. What javascript would I need to put on my simple page to do the equivalent of filling in the form and clicking the button?

    • @dassurma
      @dassurma 5 років тому +2

      Take a look at the glitch demos linked in the description! That should help you get started. Keep in mind that image share target is in Canary only. Text share target is in stable.

    • @jakearchibald
      @jakearchibald 5 років тому +1

      Check the description for super-basic examples of using share target for both text & files.

    • @dassurma
      @dassurma 5 років тому +6

      First, suckaaaaaa

    • @pdsnpsnldlqnop3330
      @pdsnpsnldlqnop3330 5 років тому

      @@jakearchibald Well that is great. I do need this functionality and I have a working PWA. I will now have to work out how to get the install working without pestering you. I am not sure if I should have that already or if it is a 'share' feature...

    • @jakearchibald
      @jakearchibald 5 років тому

      The 'manifest' section of the 'application' tab in devtools is useful for validating install issues

  • @b3rakesh11
    @b3rakesh11 5 років тому

    Awesome

  • @dmitrisheley1998
    @dmitrisheley1998 5 років тому +1

    too bad iOS would never support this... alongside 99% of bundled android browsers which most people never bother to replace.

  • @pwarelis
    @pwarelis 5 років тому

    Swanky!

    • @jakearchibald
      @jakearchibald 5 років тому

      Indeed, even my friends call me a swanker