Error: Errors in typescript@4.5 for external dependencies:
Error: node_modules/i18next/index.d.ts(2,34): error TS2691: An import path cannot end with a '.d.ts' extension. Consider importing './typescript/helpers' instead.
Error: node_modules/i18next/index.d.ts(14,8): error TS2691: An import path cannot end with a '.d.ts' extension. Consider importing './typescript/options' instead.
Error: node_modules/i18next/index.d.ts(16,43): error TS2691: An import path cannot end with a '.d.ts' extension. Consider importing './typescript/t' instead.
Error: node_modules/i18next/index.d.ts(497,1): error TS1383: Only named exports may use 'export type'.
[Net.ServicePointManager]::SecurityProtocol = "Ssl3, Tls, Tls11, Tls12"; | |
$currentDir = (Get-Item -Path "./").FullName; | |
$driversDirName = Join-Path $currentDir ".drivers"; | |
$isWindows = [System.Boolean](Get-CimInstance -ClassName Win32_OperatingSystem -ErrorAction SilentlyContinue); | |
$webClient = New-Object System.Net.WebClient; | |
function Ensure-Driver-Exists($browserName, $exeName, $download, $zipName) { | |
$localExeName = Join-Path $driversDirName $exeName; | |
if (Test-Path $localExeName) { |
function waitFor(time) { | |
return new Promise((resolve) => setTimeout(resolve, time)); | |
} | |
async function acceptVisiblePackages() { | |
const containers = document.querySelectorAll("#container"); | |
for (const container of containers) { | |
container.click(); | |
await waitFor(500); |
async function goThroughFlow() { | |
const waitFor = (time) => new Promise((resolve) => setTimeout(resolve, time)); | |
const container = document.getElementById("container"); | |
container.click(); | |
await waitFor(1000); | |
const choice = document.querySelector(`[name=discloure_choice]`); | |
choice.scrollIntoView(); | |
choice.click(); |
ESLint is generally considered to be a useful, even necessary, tool for JavaScript/TypeScript web apps. However, configuring it can involve wrangling several configurations and plugins together. It would be useful for many Astro users if npm create astro
et al. offered to set up a starting ESLint configuration.
👉 This has since been posted to DefinitelyTyped's GitHub Discussions: DefinitelyTyped/DefinitelyTyped#65993 👈
👋 Hi all! I've been working with the TypeScript team on overhauling DefinitelyTyped's usage of formatting and linting tools. Alongside the effort to finally migrate from TSLint to ESLint (https://typescript-eslint.io/linting/troubleshooting/tslint -> microsoft/DefinitelyTyped-tools#648), we'd like to align with how much of the industry & many linter maintainers recommend using a formatter vs. a linter (myself included).
This is a surfacing of a plan we've formulated that we think will get DefinitelyTyped onto using a proper formatter for formatting. I'd very much like to see the community's reaction: does this seem reasonable to you? What edge cases are we missing? Will this offend your sensibilities as a program
type Bit = 0 | 1; | |
type BitOr<A extends Bit, B extends Bit> = | |
[A, B] extends [0, 0] ? 0 : | |
[A, B] extends [0, 1] | [1, 0] | [1, 1] ? 1 : | |
Bit | |
; | |
type BitAnd<A extends Bit, B extends Bit> = | |
[A, B] extends [0, 0] | [1, 0] | [0, 1] ? 0 : |
// Yes, I know this is super hacky! Don't worry about it. | |
// In theory we could use mutation observers to check for new elements... | |
// ...but this worked well enough. 😄 | |
// Used as a script with the Run JavaScript extension: | |
// https://ataiva.com/run-javascript-chrome-extension-help | |
async function wait(seconds) { | |
await new Promise((resolve) => setTimeout(resolve, seconds)); | |
} |
I pretty much went over this post in the class 😄: https://blog.joshuakgoldberg.com/use-effect-pet-peeve/
const { promisify } = require("util"); | |
const { appendFile, writeFile } = require("fs").promises; | |
const inquirer = require("inquirer"); | |
const exec = promisify(require("child_process").exec); | |
const execAndPrint = async (command) => { | |
console.log(`> ${command}`); | |
const { stdout, stderr } = await exec(command); |