Rename Packet to Postman (#131)

This commit is contained in:
Robert 2023-06-23 22:31:25 -03:00 committed by GitHub
parent 5f300681d2
commit 5716425bd2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
13 changed files with 40 additions and 30 deletions

1
.gitignore vendored
View file

@ -8,3 +8,4 @@ node_modules/
*.conf
*.yml
*.mp3
*.sh

49
package-lock.json generated
View file

@ -3003,10 +3003,6 @@
"node": ">=6"
}
},
"node_modules/packet": {
"resolved": "packages/typescript/packet",
"link": true
},
"node_modules/parent-module": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
@ -3215,6 +3211,10 @@
"node": ">=8"
}
},
"node_modules/postman": {
"resolved": "packages/typescript/postman",
"link": true
},
"node_modules/prelude-ls": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
@ -4304,13 +4304,22 @@
},
"packages/typescript/packet": {
"version": "0.1.0",
"extraneous": true,
"license": "0BSDL",
"devDependencies": {
"@types/node": "^16.18",
"typescript": "^4.5"
}
},
"packages/typescript/packet/node_modules/@types/node": {
"packages/typescript/postman": {
"version": "0.1.0",
"license": "0BSDL",
"devDependencies": {
"@types/node": "^16.18",
"typescript": "^4.5"
}
},
"packages/typescript/postman/node_modules/@types/node": {
"version": "16.18.36",
"resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.36.tgz",
"integrity": "sha512-8egDX8dE50XyXWH6C6PRCNkTP106DuUrvdrednFouDSmCi7IOvrqr0frznfZaHifHH/3aq/7a7v9N4wdXMqhBQ==",
@ -6413,21 +6422,6 @@
"integrity": "sha512-R4nPAVTAU0B9D35/Gk3uJf/7XYbQcyohSKdvAxIRSNghFl4e71hVoGnBNQz9cWaXxO2I10KTC+3jMdvvoKw6dQ==",
"dev": true
},
"packet": {
"version": "file:packages/typescript/packet",
"requires": {
"@types/node": "^16.18",
"typescript": "^4.5"
},
"dependencies": {
"@types/node": {
"version": "16.18.36",
"resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.36.tgz",
"integrity": "sha512-8egDX8dE50XyXWH6C6PRCNkTP106DuUrvdrednFouDSmCi7IOvrqr0frznfZaHifHH/3aq/7a7v9N4wdXMqhBQ==",
"dev": true
}
}
},
"parent-module": {
"version": "1.0.1",
"resolved": "https://registry.npmjs.org/parent-module/-/parent-module-1.0.1.tgz",
@ -6563,6 +6557,21 @@
"find-up": "^4.0.0"
}
},
"postman": {
"version": "file:packages/typescript/postman",
"requires": {
"@types/node": "^16.18",
"typescript": "^4.5"
},
"dependencies": {
"@types/node": {
"version": "16.18.36",
"resolved": "https://registry.npmjs.org/@types/node/-/node-16.18.36.tgz",
"integrity": "sha512-8egDX8dE50XyXWH6C6PRCNkTP106DuUrvdrednFouDSmCi7IOvrqr0frznfZaHifHH/3aq/7a7v9N4wdXMqhBQ==",
"dev": true
}
}
},
"prelude-ls": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",

View file

@ -1,6 +1,6 @@
## About
Packet is a JavaScript library that can download the dependencies
Postman is a JavaScript library that can download the dependencies
of a web page, and afterwards display the web page with all of its
dependencies in-place, ready to use.
@ -11,7 +11,7 @@ as plain-text.
## Examples
```typescript
import packet, { item } from "packet";
import postman, { item } from "postman";
packet(
item.font("Kanit Regular", "url(/fonts/kanit-regular.ttf)"),
item.script("/js/app.js"),

View file

@ -1,5 +1,5 @@
{
"name": "packet",
"name": "postman",
"version": "0.1.0",
"description": "Download a web page's dependencies before the page loads.",
"main": "dist/index.js",

View file

@ -1,6 +1,6 @@
import type { Item, FontItem } from './packet/item';
import item from './packet/item';
import request from './packet/request';
import type { Item, FontItem } from './postman/item';
import item from './postman/item';
import request from './postman/request';
type Packet = { fetch: () => Promise<Package> };
type Items = Array<Item | FontItem>;

View file

@ -1,4 +1,4 @@
import packet, { item } from 'packet';
import postman, { item } from 'postman';
(function() {
const parent: HTMLElement = document.querySelector('.webpackage.loader')!;
@ -6,7 +6,7 @@ import packet, { item } from 'packet';
const progressNumber: HTMLSpanElement = parent.querySelector('.percentage')!;
const inlineStyle: HTMLStyleElement = document.querySelector('.css.webpackage')!;
packet(
postman(
item.script('/js/pages/surah/index.js'),
item.css('/css/pages/surah/index.css'),
item.image('/images/moon.svg'),

View file

@ -1,4 +1,4 @@
import packet, { item } from 'packet';
import postman, { item } from 'postman';
(function() {
const parent: HTMLElement = document.querySelector('.webpackage.loader')!;
@ -7,7 +7,7 @@ import packet, { item } from 'packet';
const inlineStyle: HTMLStyleElement = document.querySelector('.css.webpackage')!;
const { locale, surahId } = document.querySelector<HTMLElement>('.root')!.dataset;
packet(
postman(
item.script('/js/pages/surah/stream.js'),
item.css('/css/pages/surah/strean.css'),
item.image('/images/moon,svg'),