- Event loop
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8" /> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | |
<title>Subscriptions</title> | |
<style> | |
.subscriptions { | |
width: 100%; |
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
declare global { | |
namespace NodeJS { | |
interface Global { | |
yourUtility(...args: any[]): void; | |
} | |
} | |
} |
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 path = require('path'); | |
const webpack = require('webpack'); | |
/** @type {webpack.Configuration} */ | |
const developmentConfiguration = { | |
mode: 'development', | |
target: 'node', | |
entry: path.resolve(__dirname, './index.js'), | |
output: { | |
path: path.resolve(__dirname, 'dist', 'development'), |
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
/* | |
A valid number can be split up into these components (in order): | |
- A decimal number or an integer. | |
- (Optional) An 'e' or 'E', followed by an integer. | |
=> A decimal number can be split up into these components (in order): | |
-> (Optional) A sign character (either '+' or '-'). | |
-> One of the following formats: |
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
module.exports = { | |
// Extends the previous ESLint configuration by adding `settings` | |
// <--! Previous configuration comes here !--> | |
settings: { | |
'import/resolver': { | |
typescript: { | |
project: './tsconfig.json', | |
}, | |
}, | |
}, |
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
module.exports = { | |
// <--! Previous configuration comes here !--> | |
plugins: ['@typescript-eslint', 'prettier', 'import'], // Add "import" plugin | |
extends: [ | |
'eslint:recommended', | |
'plugin:@typescript-eslint/recommended', | |
'plugin:prettier/recommended', | |
// Extends two more configuration from "import" plugin |
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
module.exports = { | |
// Extends the previous ESLint configuration by adding rules | |
// <--! Previous configuration comes here !--> | |
rules: { | |
'sort-imports': [ | |
'error', | |
{ | |
ignoreCase: false, | |
ignoreDeclarationSort: true, // don"t want to sort import lines, use eslint-plugin-import instead | |
ignoreMemberSort: false, |
NewerOlder