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
/* | |
* Due to an API bug we are getting reversed text | |
* Write a function that takes an array of reversed strings and returns an array of unreversed strings. | |
*/ | |
const reversedStrings = ["selciheV cirtcelE muimerP", "ssenisuB ro emoH ruoy rewoP ylbaniatsuS"]; | |
function fixReversedStrings(strings) { | |
const newArray=[]; | |
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
const { createLogger, format, transports } = require('winston'); | |
const { colorize, combine, simple } = format; | |
const types = { | |
console: new transports.Console({ | |
level: 'debug', | |
format: combine( | |
colorize({ colors: { debug: 'yellow', error: 'red', info: 'blue' } }), | |
simple() |
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
// add "check": "node ./scripts/checkPublishedPackage" to the "scripts" in your package.json | |
const { exec } = require('child_process'); | |
const chalk = require('chalk'); | |
const packageName = process.argv[2]; | |
if (!packageName) { | |
console.error(chalk.red.bold('You must provide a valid package name')); | |
console.log(chalk.grey('Example:'), '`npm run check core-package`'); | |
} |
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
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"type": "node", | |
"request": "launch", | |
"name": "Jest All", | |
"program": "${workspaceFolder}/node_modules/.bin/jest", | |
"args": [], | |
"console": "integratedTerminal", |
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
{ | |
"configurations": [ | |
{ | |
"type": "node", | |
"request": "launch", | |
"name": "Jest Current File", | |
"program": "${workspaceFolder}/node_modules/.bin/jest", | |
"args": [ | |
"${workspaceFolder}/**/*.test.js", | |
"${fileBasenameNoExtension}", |
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
{ | |
"configurations": [ | |
{ | |
"name": "Gulp Debugger", | |
"type": "node", | |
"request": "launch", | |
"program": "${workspaceRoot}/node_modules/gulp/bin/gulp.js", | |
"stopOnEntry": false, | |
"args": ["-f", "${workspaceFolder}/${file}"], | |
"cwd": "${workspaceRoot}", |
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
{ | |
"configurations": [ | |
{ | |
"type": "node", | |
"request": "launch", | |
"name": "Launch via NPM", | |
"runtimeExecutable": "npm", | |
"cwd": "${workspaceFolder}", | |
"console": "integratedTerminal", | |
"runtimeArgs": [ |
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
{ | |
"configurations": [ | |
{ | |
"type": "node", | |
"request": "launch", | |
"name": "Debug AVA test file", | |
"runtimeExecutable": "${workspaceFolder}/node_modules/.bin/ava", | |
"runtimeArgs": [ | |
"debug", | |
"--config", |
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
EditorConfig for VSCode | |
ESLint | |
GitLens | |
InlineHtml | |
IntelliSnese for CSS Classnames in HTML | |
JSON | |
JSON Pretty Printer | |
Live Share | |
Markdownlint | |
npm intellisense |
OlderNewer