{
"manifest_version": 2, //Manifest 버전 (Packaged Apps는 버전2)
"name": "Hello World!", //앱 이름
"description": "My first Chrome App.", //앱 설명
"version": "0.1", //앱 버전
"app": { //Packaged Apps는 Background Script, Hosted Apps는 URL
"background": {
"scripts": ["background.js"] //실행할 Background Script 지정
}
},
//사용할 앱 아이콘 지정
"icons": { "16": "icon-16.png", "128": "icon-128.png" }
}
//크롬앱 켜질때 실행되는 코드
chrome.app.runtime.onLaunched.addListener(function() {
//윈도우 하나 새로 띄우기
//window.html - 윈도우 에 띄울 컨텐츠
chrome.app.window.create('window.html', {
'bounds': {
'width': 400,
'height': 500
}
});
});
<!--윈도우에 표시할 컨텐츠 작성--> <!DOCTYPE html> <html> <head></head> <body> <div align="center"> <h1>Hello, World!<h1> </div> </body> </html>
npm install -g yo설치끝.
npm install -g generator-chromeapp
yo chromeapp
bower install
bower search angularjs
bower install angularjs
grunt test
grunt serve
grunt