From 8c89cdb08cfcfd99875ebe9f886c905282c3c306 Mon Sep 17 00:00:00 2001 From: Philip Chimento Date: Mon, 15 Jun 2020 14:53:30 -0700 Subject: [PATCH] Rename polyfill package to 'proposal-temporal' 'tc39-temporal' sounds like something official from TC39. 'proposal-temporal' sounds like something incomplete to try out, which is what we are aiming for. --- polyfill/README.md | 6 +++--- polyfill/package.json | 2 +- polyfill/test/absolute.mjs | 2 +- polyfill/test/date.mjs | 2 +- polyfill/test/datemath.mjs | 2 +- polyfill/test/datetime.mjs | 2 +- polyfill/test/duration.mjs | 2 +- polyfill/test/exhaust.mjs | 2 +- polyfill/test/exports.mjs | 2 +- polyfill/test/intl.mjs | 2 +- polyfill/test/monthday.mjs | 2 +- polyfill/test/now.mjs | 2 +- polyfill/test/regex.mjs | 2 +- polyfill/test/resolve.cookbook.mjs | 2 +- polyfill/test/time.mjs | 2 +- polyfill/test/timezone.mjs | 2 +- polyfill/test/usercalendar.mjs | 2 +- polyfill/test/usertimezone.mjs | 2 +- polyfill/test/yearmonth.mjs | 2 +- 19 files changed, 21 insertions(+), 21 deletions(-) diff --git a/polyfill/README.md b/polyfill/README.md index c05bd99919..fcdef7dc83 100644 --- a/polyfill/README.md +++ b/polyfill/README.md @@ -19,17 +19,17 @@ A cookbook to help you get started and learn the ins and outs of Temporal is ava You can depend on the unstable Temporal polyfill in your personal projects: ```bash -$ npm install --save tc39-temporal +$ npm install --save proposal-temporal ``` In code: ```javascript -const { Temporal, Intl } = require('tc39-temporal'); +const { Temporal, Intl } = require('proposal-temporal'); ``` Or, import the polyfill as an ES6 module: ```javascript -import { Temporal, Intl } from 'tc39-temporal/lib/index.mjs'; +import { Temporal, Intl } from 'proposal-temporal/lib/index.mjs'; ``` ## Node REPL with Temporal diff --git a/polyfill/package.json b/polyfill/package.json index 975eb6d5dd..2c45c21096 100644 --- a/polyfill/package.json +++ b/polyfill/package.json @@ -1,5 +1,5 @@ { - "name": "tc39-temporal", + "name": "proposal-temporal", "version": "0.1.0", "description": "Experimental polyfill for the TC39 Temporal proposal", "type": "commonjs", diff --git a/polyfill/test/absolute.mjs b/polyfill/test/absolute.mjs index 715d246653..5f14ba6e29 100644 --- a/polyfill/test/absolute.mjs +++ b/polyfill/test/absolute.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal, notEqual, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const { Absolute } = Temporal; describe('Absolute', () => { diff --git a/polyfill/test/date.mjs b/polyfill/test/date.mjs index 455246fda9..2cae4d9f83 100644 --- a/polyfill/test/date.mjs +++ b/polyfill/test/date.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal, notEqual, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const { Date } = Temporal; describe('Date', () => { diff --git a/polyfill/test/datemath.mjs b/polyfill/test/datemath.mjs index 1e0bccbc59..b1f0220c25 100644 --- a/polyfill/test/datemath.mjs +++ b/polyfill/test/datemath.mjs @@ -13,7 +13,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('Date.difference(simple, simple)', () => { build('Before Leap Day', '2020-01-03', '2020-02-15'); diff --git a/polyfill/test/datetime.mjs b/polyfill/test/datetime.mjs index f5ffb0ade1..30f7726f84 100644 --- a/polyfill/test/datetime.mjs +++ b/polyfill/test/datetime.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal, notEqual, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const { DateTime } = Temporal; describe('DateTime', () => { diff --git a/polyfill/test/duration.mjs b/polyfill/test/duration.mjs index 5a249b4c3e..2ade3e4dd2 100644 --- a/polyfill/test/duration.mjs +++ b/polyfill/test/duration.mjs @@ -7,7 +7,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { throws, equal, notEqual } = assert; -import { Duration } from 'tc39-temporal'; +import { Duration } from 'proposal-temporal'; describe('Duration', () => { describe('Structure', () => { diff --git a/polyfill/test/exhaust.mjs b/polyfill/test/exhaust.mjs index 4fe18c30e0..ee3fb2704d 100644 --- a/polyfill/test/exhaust.mjs +++ b/polyfill/test/exhaust.mjs @@ -1,4 +1,4 @@ -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const all = process.argv[2] === 'all'; const start = new Temporal.Date(1999, 1, 1); diff --git a/polyfill/test/exports.mjs b/polyfill/test/exports.mjs index f6966e876c..ae03c807a3 100644 --- a/polyfill/test/exports.mjs +++ b/polyfill/test/exports.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('Exports', () => { const named = Object.keys(Temporal); diff --git a/polyfill/test/intl.mjs b/polyfill/test/intl.mjs index 0a2fbe42ce..c6e63ada97 100644 --- a/polyfill/test/intl.mjs +++ b/polyfill/test/intl.mjs @@ -9,7 +9,7 @@ const { deepEqual, equal, throws } = assert; import { DateTimeFormat } from '../lib/intl.mjs'; Intl.DateTimeFormat = DateTimeFormat; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('Intl', () => { // TODO: move these to their respective test files. diff --git a/polyfill/test/monthday.mjs b/polyfill/test/monthday.mjs index 39113c846b..8b015919fd 100644 --- a/polyfill/test/monthday.mjs +++ b/polyfill/test/monthday.mjs @@ -7,7 +7,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { throws, equal, notEqual } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const { MonthDay } = Temporal; describe('MonthDay', () => { diff --git a/polyfill/test/now.mjs b/polyfill/test/now.mjs index c5868ab24d..47648720d8 100644 --- a/polyfill/test/now.mjs +++ b/polyfill/test/now.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('Temporal.now', () => { describe('Structure', () => { diff --git a/polyfill/test/regex.mjs b/polyfill/test/regex.mjs index 8a5b42c3f1..7956aad49f 100644 --- a/polyfill/test/regex.mjs +++ b/polyfill/test/regex.mjs @@ -7,7 +7,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('fromString regex', () => { describe('absolute', () => { diff --git a/polyfill/test/resolve.cookbook.mjs b/polyfill/test/resolve.cookbook.mjs index 6901af6a25..e5f10112a3 100644 --- a/polyfill/test/resolve.cookbook.mjs +++ b/polyfill/test/resolve.cookbook.mjs @@ -15,7 +15,7 @@ export function resolve(specifier, parent, defaultResolve) { export async function transformSource(source, { url, format }, defaultTransformSource) { if (typeof source === 'string' && url !== 'all.mjs' && !url.endsWith('polyfill/lib/index.mjs')) { return { - source: "import { Temporal } from 'tc39-temporal';\nimport assert from 'assert';\n" + source + source: `import { Temporal } from '${PKG.name}';\nimport assert from 'assert';\n` + source }; } else { // source could be a buffer, e.g. for WASM diff --git a/polyfill/test/time.mjs b/polyfill/test/time.mjs index 3aaf21f796..50d394f61f 100644 --- a/polyfill/test/time.mjs +++ b/polyfill/test/time.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal, notEqual, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const { Time } = Temporal; describe('Time', () => { diff --git a/polyfill/test/timezone.mjs b/polyfill/test/timezone.mjs index 4b593c9004..eed93f2c7d 100644 --- a/polyfill/test/timezone.mjs +++ b/polyfill/test/timezone.mjs @@ -14,7 +14,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { deepEqual, equal, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('TimeZone', () => { describe('Structure', () => { diff --git a/polyfill/test/usercalendar.mjs b/polyfill/test/usercalendar.mjs index 3207fc4c07..01eeaeedd6 100644 --- a/polyfill/test/usercalendar.mjs +++ b/polyfill/test/usercalendar.mjs @@ -12,7 +12,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('Userland calendar', () => { describe('Trivial subclass', () => { diff --git a/polyfill/test/usertimezone.mjs b/polyfill/test/usertimezone.mjs index 26ada0198e..1aba2a2b7e 100644 --- a/polyfill/test/usertimezone.mjs +++ b/polyfill/test/usertimezone.mjs @@ -12,7 +12,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { equal, throws } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; describe('Userland time zone', () => { describe('Trivial subclass', () => { diff --git a/polyfill/test/yearmonth.mjs b/polyfill/test/yearmonth.mjs index 200ad33cc2..27902267c3 100644 --- a/polyfill/test/yearmonth.mjs +++ b/polyfill/test/yearmonth.mjs @@ -7,7 +7,7 @@ const { reporter } = Pretty; import { strict as assert } from 'assert'; const { throws, equal, notEqual } = assert; -import * as Temporal from 'tc39-temporal'; +import * as Temporal from 'proposal-temporal'; const { YearMonth } = Temporal; describe('YearMonth', () => {