I think my code is correct! Why it is complaining type error to me?
How can I do something in TypeScript?
function add(left: T, right: T): T {
//// Case 1 | |
// before | |
len = len > 32 ? (len > 48 ? 66 : 48) : 32 | |
// after | |
len = | |
len > 32 ? | |
len > 48 ? | |
66 | |
: 48 |
{ | |
"version": "0.2.0", | |
"configurations": [ | |
{ | |
"type": "node", | |
"request": "launch", | |
"name": "Mocha Tests (currently opened test)", | |
"runtimeArgs": ["--nolazy"], | |
"program": "${workspaceRoot}/node_modules/mocha/bin/_mocha", | |
"args": [ |
#! Aaaaaaaaaaa this is JS!!! | |
// https://github.com/tc39/proposal-hashbang | |
// This file is mixing all new syntaxes in the proposal in one file without considering syntax conflict or correct runtime semantics | |
// Enjoy!!! | |
// Created at Nov 23, 2018 | |
for await(const x of (new A // https://github.com/tc39/proposal-pipeline-operator | |
|> do { // https://github.com/tc39/proposal-do-expressions | |
case(?) { // https://github.com/tc39/proposal-pattern-matching | |
when {val}: class { |
function sleep(ms) { | |
return new Promise((resolve) => setTimeout(resolve, ms)) | |
} | |
async function err() { | |
await sleep(200) | |
// debugger: pause on uncaught exception | |
// should pause on this | |
throw new Error("wow") | |
} | |
function err2() { |
// ==UserScript== | |
// @name NPM detect ESM TS sideEffects | |
// @namespace http://tampermonkey.net/ | |
// @version 0.3 | |
// @description | |
// @author Jack Works | |
// @match https://www.npmjs.com/* | |
// @grant GM_xmlhttpRequest | |
// @require https://unpkg.com/@holoflows/[email protected] | |
// @connect unpkg.com |
I hereby claim:
To claim this, I am signing this object: