-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(esm): support import attributes (#30482)
Fixes #30473
- Loading branch information
1 parent
02c0706
commit f5ca524
Showing
6 changed files
with
352 additions
and
1,127 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
1,189 changes: 187 additions & 1,002 deletions
1,189
packages/playwright/bundles/babel/package-lock.json
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
const { chromium } = require('playwright'); | ||
|
||
(async () => { | ||
const browser = await chromium.launch(); | ||
const page = await browser.newPage(); | ||
const packageJSON = require('./package.json'); | ||
for (const dep of Object.keys(packageJSON.dependencies)) { | ||
await page.waitForTimeout(3000); | ||
console.log('Processing ', dep); | ||
await page.goto(`https://www.npmjs.com/package/${dep}`); | ||
const title = await page.getByText('Public').locator('..').textContent(); | ||
if (!title.startsWith(dep)) | ||
throw new Error('Malformed title: ', title); | ||
const i = title.indexOf(' • Public'); | ||
if (i === -1) | ||
throw new Error('Malformed title: ' + title); | ||
const version = title.slice(dep.length, i); | ||
console.log(version); | ||
packageJSON.dependencies[dep] = '^' + version; | ||
} | ||
await browser.close(); | ||
console.log(JSON.stringify(packageJSON, null, 2)); | ||
})(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters