为什么webextension安装失败?

时间:2016-09-30 12:51:57

标签: javascript json firefox-webextensions

我正在学习如何写webextensions 所以我从头开始复制here的“beastify”扩展名。

但我的复制版本的安装失败 我不知道为什么安装失败。

目录结构相同,代码含义相同,图片文件相同。

我认为manifest.json中存在安装失败的原因。

我的manifest.json:

{
    "manifest_version": 2,
    "name": "Beastify",
    "version": 1.0,

    "description": "add a browser action icon to the toolbar. Click the button to choose a beast. The active tab's body content is then replaced with a picture of the choosen beast.",
    "icons": {
        "48": "icons/beasts-48.png"
    },

    "permissions": [
        "activeTab"
    ],

    "browser_action": {
        "default_icon": "icons/beasts-32.png",
        "default_title": "Beastify",
        "default_popup": "popup/choose_beast.html"
    },

    "web_accessible_resources": [
        "beasts/frog.jpg",
        "beasts/turtle.jpg",
        "beasts/snake.jpg"
    ]
}

1 个答案:

答案 0 :(得分:1)

version的值必须为字符串 请将"version": 1.0,替换为"version": "1.0",