Skip to content

Instantly share code, notes, and snippets.

View jeremy-code's full-sized avatar

Jeremy Nguyen jeremy-code

View GitHub Profile
@jeremy-code
jeremy-code / README.md
Created May 24, 2025 10:33
Moore & Ward

Pioneer Photographers from the Mississippi to the Continental Divide: A Biographical Dictionary, 1839-1865, Peter E. Palmquist, Thomas R. Kailbourn, 2005, Page 447

[Justus E. Moore and Captain Ward] received official permission to set up their daguerreian apparatus in the Capitol, including in the private chambers of Vice President Johnson and in the chamber of the Senate Committee on Military Affairs. In early March, Moore wrote that he and Ward had "taken many likenesses of the most distinguished members of the Senate and the House of Representatives." Even newly elected President William Henry Harrison sat for Moore and Ward in early March; their portrait of Harrison is thought to have been the first ever taken of a president, and probably was the last portrait taken of him before his death in April 1841.

Sources:

  1. Thomas M. Weprich, "The Pencil of Nature in Washington, D.C.: Daguerre-otyping the President," Daguerreian Annual 1995 (Pittsburgh: Daguerreian Society,1995), pp. 115, 117 nn. 1-3; New Yor
@jeremy-code
jeremy-code / README.md
Created May 24, 2025 07:27
Desk of the Presiding Officer of the United States Senate 1858 - 1949
  • Designed by Thomas U. Walter in 1858
  • Historic walnut desk
  • Occupied by the presiding officer of the United States Senate since 1858 - 1949
  • First user was Vice President John Breckenridge (1857-1861)
  • Last user was Vice President Alben W. Barkley from January 3, 1949 to July 1949

A color photo of the Research/ Reading Room in Margaret I. King North Library. The desk at the left was Vice President Barkley's desk from the United States Senate. Photographer: Terry Warth, 1985, University of Kentucky, University of Kentucky general photographic prints

@jeremy-code
jeremy-code / README.md
Last active May 16, 2025 01:06
WH Artifacts

For any losers like me who wanted a list of all the art owned by the White House and their histories: I found this pdf from Gerald Ford for "Items acquired for the White House Collection 1973-1974" (I think the heading is wrong because there are some things from 1970, 1972, etc.). I guess there was some controversy that https://en.wikipedia.org/wiki/Lansdowne_portrait was not done by Stuart

https://www.fordlibrarymuseum.gov/sites/default/files/pdf_documents/library/document/0018/81556669.pdf

If you want the NARA url it's here https://catalog.archives.gov/id/81556669

Box 33, folder “Curator's Office - General (3)” of the Betty Ford White House Papers, 1973-1977 at the Gerald R. Ford Presidential Library. Curator's Office - General (3)

@jeremy-code
jeremy-code / README.md
Created May 14, 2025 05:53
Roosevelts Portraits in Roosevelt Room

Even before President Nixon formally named it the Roosevelt Room, a tradition existed of Democratic administrations hanging Alfred Jonniaux's portrait of Franklin D. Roosevelt over the mantel with Theodore Roosevelt's equestrian portrait by Tade Styka titled Rough Rider hung on the south wall. Republican administrations hung Teddy Roosevelt's painting above the mantel and moved FDR's portrait to the south wall. Bill Clinton decided to keep the landscape formatted Teddy Roosevelt portrait above the mantel and FDR's portrait on the south wall.

FDR: (1933-1945) Can't find anything here other than he had an aquarium and fish in here. I find it unlikely he would put a picture of himself up and Alfred Jonniaux's portrait of Franklin D. Roosevelt hadn't been painted yet (1958).

Truman

Can't find anything here either.

Eisenhower

@jeremy-code
jeremy-code / README.md
Last active May 2, 2025 04:14
VSCode C/C++ Emscripten Set up

Suppose you want to set up VSCode with Emscripten. In my case, I am using devcontainers with Docker and Emscripten's official Docker image (emscripten/emsdk), but any VSCode installation should do.

Run emconfigure env and you should get an output similar to this:

...
EM_CONFIG=/emsdk/.emscripten
CC=/emsdk/upstream/emscripten/emcc
CXX=/emsdk/upstream/emscripten/em++
AR=/emsdk/upstream/emscripten/emar
@jeremy-code
jeremy-code / README.md
Last active May 7, 2025 01:56
Emscripten Embind Enums

Suppose you are wanting to use Emscripten's Embind with an Enum.

// exif-byte-order.h
typedef enum {
	EXIF_BYTE_ORDER_MOTOROLA,
	EXIF_BYTE_ORDER_INTEL
} ExifByteOrder;
@jeremy-code
jeremy-code / README.md
Created April 27, 2025 04:54
Emscripten sizeof types in bytes C WASM64
// main.c

#include <emscripten.h>

int EMSCRIPTEN_KEEPALIVE main() {
    printf("sizeof(bool): %zu\n", sizeof(bool));
    printf("sizeof(char): %zu\n", sizeof(char));
    printf("sizeof(signed char): %zu\n", sizeof(signed char));
    printf("sizeof(unsigned char): %zu\n", sizeof(unsigned char));
@jeremy-code
jeremy-code / README.md
Last active April 23, 2025 07:15
Runtime methods in Emscripten

A list of (some) of the runtime methods avaliable in Emscripten. You can also find some more in https://emscripten.org/docs/api_reference/preamble.js.html There's a lot more -- search repo:emscripten-core/emscripten path:src/lib/lib*.js with GitHub search to see the avaliable paths, but these are the autogenerated types:

declare namespace RuntimeExports {
    /**
     * @param {string|null=} returnType
     * @param {Array=} argTypes
     * @param {Arguments|Array=} args
     * @param {Object=} opts
     */
I wanted to see which browsers supported XSLT (caniuse only lists the XSLTProcessor API)
- Internet Explorer 5, with the MSXML3 add-on; natively in Internet Explorer 6 ([source](https://web.archive.org/web/20010208095513/http://msdn.microsoft.com/library/psdk/xmlsdk/xslp44kx.htm))
- Mozilla 0.9 ([source](https://web.archive.org/web/20010413155836/http://www.mozilla.org:80/projects/xslt/))
- Chrome quotes [Firefox 1.5](https://developer.mozilla.org/en-US/docs/Mozilla/Firefox/Releases/1.5)
- WebKit 3 ([source](https://www.webkit.org/blog/122/webkit-3-10-new-things/)), WebKit used to have an [Open Source page](https://web.archive.org/web/20061011203342/http://webkit.org/projects/xslt/index.html) on this
- Chrome: just says 1 ([source](https://chromestatus.com/feature/4730954895589376))
> A use counter measurement from the Chrome Beta channel indicates that less than 0.02% of page views use XSLT. Moreover, less than 0.003% of page view use the XSLT processing instruction. (The balance use XSLT via the XSLT
@jeremy-code
jeremy-code / README.md
Created April 20, 2025 22:48
JSPI Emscripten C

JavaScript Promise Integration (JSPI) is a Phase 4 (Standardize the Feature) WebAssembly proposal for running asynchronous Web APIs alongside synchronous code.

JSPI is supported under the following browsers/engines through enabling a feature flag:

Chrome: chrome://flags/#enable-experimental-webassembly-jspi

Firefox: javascript.options.wasm_js_promise_integration

Node.js: --experimental-wasm-jspi