Content_script doesn't load

Hi all, I am new on Add-ons and have what it is probably a silly question, however, I haven’t been able to load any content_script. I have tried to include the script in two ways, via the “manifest.json” with the “content_scripts” properties and using the “browser.tabs.executeScript()” method from the script.js file under the browserAction folder.
the current structure, manifest and script from where is injected of my project are as follows:

browserAction
|__index.html
|__script.js
|__style.css
background.js
content_script.js
manifest.json

manifest.json

{
	"manifest_version": 2,
	"name": "Highlight",
	"description": "Highlight text",
	"version": "0.0.1",
	"icons": {
		"64": "icons/icon.png"
	},
	"permissions": [
		"activeTab",
		"contextMenus"
	],
	"content_scripts": [
		{
			"matches": ["*://*.mozilla.org/*"],
			"js": ["content_script.js,"],
			"all_frames": true
		}
	],
	"background": {
        "scripts": [
            "background.js"
        ]
    },
	"browser_action": {
		"default_icon": {
			"64": "icons/icon.png"
		},
		"default_popup": "browserAction/index.html",
		"default_title": "Highlight"
	},
	"page_action": {
		"default_icon": {
			"64": "icons/icon.png"
		},
		"default_popup": "pageAction/index.html",
		"default_title": "Highlight"
	},
	"options_ui": {
		"page": "options/index.html"
	}
}

script.js

    function start() {
    function selectText() {
    let selectedText = '';

    if (window.getSelection) {
        selectedText = window.getSelection();
    } else if (document.getSelection) {
        selectedText = document.getSelection();
    } else if (document.selection) {
        selectedText = document.selection.createRange().text
    }
    
    console.log(selectedText.toString());
};

function onError(error) {
    console.log(error);
}

browser.tabs.executeScript({file: "../content_script/index.js"})
.then(selectText)
.catch(onError);

};
start();

I see you’re using *.mozilla.org content scripts. Where are you testing? On developer.mozilla.org? If so, also make sure you’re not testing in a private window (or have permanent private browsing enabled).

Lastly, how do you decide if your content script ran?

To add on what freaktechnik said, if you are trying this on one of the following domain listed at


it will fail and the page will log a CSP error.

Thanks guys for your quick answer. The way I manage to made it work was removing “content_scripts” property from the manifest and just inject the script from the browser action file. It works just fine for what I need. The documentation pointed was really useful.