How do I change my "legacy packaged app" into an "extension"?
google-chrome-app, google-chrome-extension, legacy-app, manifest
Solution
For an app use a manifest that looks like:
{
// Required
"app": {
"background": {
// Optional
"scripts": ["background.js"]
}
},
"manifest_version": 2,
"name": "My App",
"version": "versionString",
...
For an extension use
{
// Required
"manifest_version": 2,
"name": "My Extension",
"version": "versionString",
// Recommended
"default_locale": "en",
"description": "A plain text description",
"icons": {...},
// Pick one (or none)
"browser_action": {...},
"page_action": {...},
...
Problem
I have looked at the Google documentation but I can't see how to change its type. This is the error I get on loading. There were warnings when trying to install this extension: 'browser_action' is only allowed for extensions, and this is a legacy packaged app. This is my manifest.json. ``` { "name": "first app", "description": "this is my first app", "version": "1.4", "manifest_version": 2, "content_security_policy": "script-src 'self' https://en.wiktionary.org/; object-src 'self'", "background": { "page": "background.html" }, "app": { "launch": { "local_path": "index.html" } }, "browser_action": { "default_icon": "icon.png" }, "icons": { "128": "icon.png", "16": "icon.png" }, "permissions": [ "http://*/*", "https://*/*", "https://en.wiktionary.org/", "http://en.wiktionary.org/", "tabs", "contextMenus", "storage", "unlimitedStorage", "notifications"] } ``` All I have is a right-click event at any-time while browsing and store that text for viewing on a main page. I added in the "browser_action" as the chrome store isn't alowing me to upload my extension as a "legacy packaged app", but I don't really understand what that is even after reading the documentation.