This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// before | |
function isOutsideInterval(value, minimum, maximum, limits) { | |
return value < limits.minimum || value > maximum; | |
} | |
// after | |
function isOutsideInterval(value, minimum, maximum, limits) { | |
return value < limits.minimum || value > limits.maximum; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// before | |
const shouldShowError = isOutsideInterval(value, minimum, maximum, { | |
minimum, | |
maximum | |
}); | |
function isOutsideInterval(value, minimum, maximum, limits) { ... } | |
// after |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// before | |
const shouldShowError = isOutsideInterval(value, { | |
minimum, | |
maximum | |
}); | |
// after | |
const limits = { minimum, maximum }; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"manifest_version": 2, | |
"name": "Borderify", | |
"version": "1.0", | |
"description": "Adds a red border to all webpages matching mozilla.org.", | |
"icons": { | |
"48": "icons/border-48.png" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "Getting Started Example", | |
"version": "1.0", | |
"description": "Build an Extension!", | |
"manifest_version": 2 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "my-first-extension", | |
"version": "1.0", | |
"manifest_version": 2 | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"name": "my-first-extension", | |
"version": "1.0.0", | |
"manifest_version": 2, | |
"application": { | |
"id": "myfirstextension@evgenii.info" | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getAllDragons() { | |
try { | |
const infoAboutDragons = DATABASE.getAll({type: 'dragons'}); | |
return infoAboutDragons; | |
} catch (ex) { | |
throw new DatabaseError(); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getInformationAboutPets() { | |
const cats = CAT_SERVICE.getAllCats(); | |
const dogs = DOG_SERVICE.getAllDogs(); | |
const dragons = DRAGON_SERVICE.getAllDragons(); | |
return [cats, dogs, dragons]; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
web-ext sign --api-key=user:14760837:724 --api-secret=967445ccc5c6127bd423dcb6b2d2fe00e23471ec60d22d52fa6aec0857c0ad5e |