Skip to content
This repository has been archived by the owner on May 26, 2023. It is now read-only.

Components

Kunal Chaudhary edited this page Oct 10, 2016 · 2 revisions

There are various components of Facebook_Timer extension which are explained as follows:-

  • manifest.json
    manifest is nothing more than a metadata file in JSON format that contains properties like extension's name, description, version number and so on. At a high level, it is used to declare to Chrome what the extension is going to do, and what permissions it requires in order to do those things.

All the files written inside content_scripts of manifest.json file are injected on facebook's page and will be referred to as content-script from now.

  • icon.png
    This is an image file which shows as action icon of the extension.

  • timer.js
    This is the main content-script of this extension. This JavaScript file is injected in facebook's page by the extension. Tasks like displaying timer on facebook's page and updating + storing timer values is done by this script.
    Dependencies: functions.js

  • functions.js
    Various timer functions and functions for storing and retriving timer using Chrome Storage API is implemented in this JavaScript file. This file is injected on facebook's page before our content-script timer.js file. See the manifest.json file -> functions.js is written before timer.js.

  • popup.js
    This JavaScript file is not used as a content-script. This is included in the popup page of extension. popup page shows up on clicking the action key of extension.
    Dependencies: functions.js

  • popup.html
    This is our popup page and shows up on clicking the action icon of the extension. It shows up Total Usage and Current Usage of facebook and have 2 buttons - Refresh and Reset Current Timer.

  • style.css
    This is the stylesheet file which contains css properties aka styling of popup page and timer that is shown of facebook's page.

All other files - LICENSE, README.md and wiki_files directory have no role in functionality of this extension.

  • User Guide
Clone this wiki locally