抹桥的博客
Language
Home
Archive
About
GitHub
Language
主题色
250
325 words
2 minutes
My First Chrome App

As is well known, OneDrive is a personal cloud storage service provided by Microsoft. It offers 25GB of free space to old users and 7GB to newly registered users. It would be fantastic if this space could be used as an image host for blogs. After all, Microsoft is a financially robust company, and it’s unlikely to be easily blocked in China, so its stability is guaranteed. However, the public links provided by OneDrive cannot be directly embedded into blog posts; they require a certain format conversion. I found a method online to convert these links, but doing it manually is too cumbersome. So, I thought about creating a Chrome extension, for convenience.

I took a quick look at the APIs provided by Chrome and found that creating a simple application is actually quite straightforward. So, I got to work. Below is a screenshot of the finished product. onedrive I’ve also embedded the content directly here, so you can convert links right on this page:

Public Link: File Type: Converted Address:

Its function: By entering the public link obtained from OneDrive and the file type, you can get a directly accessible address for that file. It consists of four basic files:

  • manifest.json
  • popup.html
  • popup.css
  • popup.js

The first file contains the application’s description information, while the latter three files are the application’s content, styles, and logic, respectively. Essentially, it’s just like a regular webpage.


Since I haven't opened a developer account yet, I can't submit it to the Chrome Web Store. However, you can download it here: [Click here](http://pan.baidu.com/s/1kTtE7EB). After downloading, it cannot be installed directly; you'll need to manually drag it to the extension management page, and then you can use it freely.

If you’re interested in the source code, then: Click here

This article was published on January 12, 2015 and last updated on January 12, 2015, 3920 days ago. The content may be outdated.

My First Chrome App
https://blog.kisnows.com/en-US/2015/01/12/chrome-extension-firsttime/
Author
Kisnows
Published at
2015-01-12
License
CC BY-NC-ND 4.0