I am developing a small extension for chromium and I will do a script injection when the user loads a specific page.
manifest.json
    {
    "name" : "e-CalendarL3",
    "description": "Extension pour les L3 informatique étudiant à l'université d'Angers",
    "version": "0.0.1",
    "background" : {
        "scripts" : ["background.js"],
        "persistent": true
    },
    "permissions":["webNavigation","storage","activeTab"],
    "browser_action": {
        "default_popup": "popup.html"
    },
    "content_scripts": [
        {
        "matches": ["https://edt.univ-angers.fr/edt/*"],
        "js": ["injection.js"],
        "run_at": "document_end"   
        }
    ], 
    "manifest_version": 2
}
background.js
chrome.runtime.onInstalled.addListener(function() {
    alert('Merci d\'avoir installé l\'extension ');
})
injection.js
var aGrid = document.getElementsByClassName('fc-time-grid-event');
console.log(aGrid); // works
console.log(aGrid[0]) // don't works
console.log(aGrid.length); // don't works
console.log(aGrid); // works
injection.js result in the console

the html collection is not empty and it is correctly displayed but the other two lines of the injection.js script cause me problems (line 3 and 4) for example line 4 should return to me 24
 
    