Skip to content

Instantly share code, notes, and snippets.

Avatar

Christopher Chedeau vjeux

View GitHub Profile
View test_results.js
(517) >> yarn test
Using globally installed version of Yarn
yarn run v1.12.1
$ jest src/*
(node:37909) UnhandledPromiseRejectionWarning: Error: Callback didn't resolve
(node:37909) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 1)
(node:37909) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
(node:37909) UnhandledPromiseRejectionWarning: Error: Callback didn't resolve
(node:37909) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function
View tldr.md

tldr of https://serokell.io/blog/2018/12/17/why-dependent-haskell

Standard Haskell: Ergonomics + Performance

He basically wants a language with a type system that lets you ensure that reading an element at an arbitrary position is safe and cannot crash because the index is always within the range of the array. He goes through all the mainstream languages and finds out that none would work.

Agda: Ergonomics + Correctness

He gives an example of a language that has this property, Agda. It's actually not a traditional language but a proof assistant. The way lookup is defined is the following way:

@vjeux
vjeux / x.md
Last active Jun 19, 2019
Ocaml / functional programming
View x.md

I'm taking down this post. I just posted this as a side comment to explain a sentence on my latest blog post. This wasn't meant to be #1 on HN to start a huge war on functional programming... The thoughts are not well formed enough to have a huge audience. Sorry for all the people reading this. And please, don't dig through the history...

View nuclide.diff
diff --git a/modules/nuclide-commons-ui/styles/Table.less b/modules/nuclide-commons-ui/styles/Table.less
index 8e672829a..2c73ab617 100644
--- a/modules/nuclide-commons-ui/styles/Table.less
+++ b/modules/nuclide-commons-ui/styles/Table.less
@@ -30,8 +30,7 @@
width: 100%;
}
-.nuclide-ui-table-header-cell,
-.nuclide-ui-table-body-cell {
View nuclide.diff
diff --git a/modules/nuclide-commons-ui/styles/Checkbox.less b/modules/nuclide-commons-ui/styles/Checkbox.less
index 729a6d725..48ab20fc9 100644
--- a/modules/nuclide-commons-ui/styles/Checkbox.less
+++ b/modules/nuclide-commons-ui/styles/Checkbox.less
@@ -1,7 +1,8 @@
@import "ui-variables";
.nuclide-ui-checkbox-label, .nuclide-ui-toggle-label {
- margin-bottom: 0; // This is to override a default in bootstrap.
+ margin-bottom: 0;
View apollo-prettier-2.js
(592) >> find ../apollo-client/ -name '*.ts' | xargs bin/prettier.js --parser typescript --debug-check
../apollo-client//benchmark/index.ts
../apollo-client//benchmark/util.ts
../apollo-client//fetch-mock.typings.d.ts
prettier(input) !== prettier(prettier(input))
Index:
===================================================================
---
+++
@@ -27,5 +27,5 @@
View apollo-prettier
(521) >> find . -name '*.ts' | xargs ~/random/prettier/bin/prettier.js --parser typescript --debug-check
./benchmark/index.ts
./benchmark/util.ts
ast(input) !== ast(prettier(input))
Index:
===================================================================
---
+++
@@ -1599,27 +1599,26 @@
"operator": "||",
View typescript.js
This file has been truncated, but you can view the full file.
prettier vjeux$ find ../TypeScript/tests/ -name '*.ts' | grep -v "'" | xargs ./bin/prettier.js --parser typescript --debug-check
../TypeScript/tests/baselines/reference/project/declarationDir/amd/declarations/a.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir/amd/declarations/subfolder/b.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir/amd/declarations/subfolder/c.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir/node/declarations/a.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir/node/declarations/subfolder/b.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir/node/declarations/subfolder/c.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir2/amd/declarations/a.d.ts
../TypeScript/tests/baselines/reference/project/declarationDir2/amd/declarations/subfolder/b.d.ts
View bad.js
Summary of all failing tests
FAIL tests/jsx-stateless-arrow-fn/jsfmt.spec.js
flow - undefined-verify
expect(value).toMatchSnapshot()
Received value does not match stored snapshot 1.
- Snapshot
+ Received
View help.md
a(
  SomethingVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryLong,
  [
    {
      SomethingVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryVeryLong: 1
    }
  ]
);
You can’t perform that action at this time.