- Migrations (if applicable)
- Seeders (if applicable)
- Automated Tests
- Integration
- E2E
- Authentication
- Authorization
- Documentation
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 extractPropsToArray(obj, arr = [], path = "") { | |
for (const key in obj) { | |
if (Object.hasOwnProperty.call(obj, key)) { | |
const element = obj[key]; | |
const isObject = typeof element === "object"; | |
if (isObject) { | |
const pathname = Boolean(path) ? `${path}.${key}` : `${key}` | |
extractPropsToArray(element, arr,pathname ) | |
} else { | |
const pathname = Boolean(path) ? `${path}.${key}` : `${key}` |
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
/* | |
Implement the setInterval function in such a way that calling SetInterval.prototype.start | |
will start the function passed to it and run the function at intervals `interval` until | |
the SetInterval.prototype.clear method is called. | |
For example: | |
const theIntervalRunner = SetInterval(()=> console.log("logging'), 1000) | |
theIntervalRunner.start() | |
setTimeout(() => theIntervalRunner.clear(), 5000) |
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
{ | |
// Place your snippets for javascript here. Each snippet is defined under a snippet name and has a prefix, body and | |
// description. The prefix is what is used to trigger the snippet and the body will be expanded and inserted. Possible variables are: | |
// $1, $2 for tab stops, $0 for the final cursor position, and ${1:label}, ${2:another} for placeholders. Placeholders with the | |
// same ids are connected. | |
// Example: | |
// "Print to console": { | |
// "prefix": "log", | |
// "body": [ | |
// "console.log('$1');", |
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
class Vehicle{ | |
factory Vehicle(int numberOfTyres) { | |
// An if-else statement can be used too | |
switch (numberOfTyres) { | |
case 2: | |
return Motorcycle(); | |
case 3: | |
return Tricycle(); | |
case 4: |