Chrome packaged apps 與 Content Security Policies.

延續前一篇的Chrome Apps 開發 samples
可以先一起走一遍 follow the official Codelab presented at Google I/O 做中學。

其中有講到一些觀念,

像是Chrome Apps 不會是靠網路,都是local控制,使用者可以完整控制App的週期。開發者要注意的是,需要確保資料都是local儲存,offline可以讀取,當有網路的時候可以sync。

另外本文重點就是Content Security Policies (CSP)

Chrome packaged apps platform force your app to be fully compliant with Content Security Policies. This includes not being able to directly load DOM resources, like images, fonts and CSS's from outside of your app.

If you want to show an external image in your app, you need to request it via XHR, transform it into a Blob and create an ObjectURL. This ObjectURL can then be added to the DOM, because it refers to an in-memory item in the context of the app.


覺得微妙,要好好研究一下。
未完待續 Orz

To learn more about how to develop Chrome Apps:

留言

Google

本月熱門文章

香港朋友,真的對唔住,台灣出了這種中共的幫兇!

堅持5個月!反送中示威者六大特色 6 features of Hong Kong Anti-ELAB Protesters│老外看香港│郝毅博 Ben Hedges│新唐人電視台

[黑金] 台南88槍擊案主犯國民黨學甲區黨部主委王文宗 也擔任統促黨幹部

熱門文章

企鵝妹/柳允進 史上最暈的TT三分鐘完整版一次看個夠

陳昇 Bobby Chen【把悲傷留給自己 I left sadness to myself】Official Music Video

裝潢師傅貼圖來了唷

香港朋友,真的對唔住,台灣出了這種中共的幫兇!

新手自建監控雲最快的方式:推薦QNAP NAS 搭配QVR Pro

2020 中華民國 台灣 失業補助申請方式 失業給付申請

香港朋友看服貿 - 嗨,我是香港人,一個CEPA的受害者。

堅持5個月!反送中示威者六大特色 6 features of Hong Kong Anti-ELAB Protesters│老外看香港│郝毅博 Ben Hedges│新唐人電視台