diff --git a/README.md b/README.md index 1587749..786ef68 100644 --- a/README.md +++ b/README.md @@ -15,17 +15,46 @@ - Requires node 22 - To save time, I recommend globally aliasing the `nx` command to `npx nx` or global installed `npm i -g nx`. +## Features + +1. Determine if a browser download of an asset works on your platform. Meant for native mobile, desktop, server download testing. +2. Determine if a browser asset can render if given base64 or a blob file. + +### Covers the following cases + +- Assets can be downloaded via previews +- Base64 assets +- Blob assets (from local browser that need to be downloaded on the client) +- anchor tags with download attribute and a url asset + +### UI + +The WebUI allows the user to click a specific file type. Currently only `.png` and `.webp` have actual assets that will load actual data. + +Other file types can be generated via the command `npm run generate-assets` which will add more assets, all at 1 MegaByte in size. + +This can be configured if you want within the [make-files.sh](scripts/make-files.sh) script example if you want to test downloading a 500MB files. You could swap the file size to `FILE_SIZE="500mb"` which would make files take a long time to download and likely would not work well with base64 from the server since it sends the entire string. + +#### Example UI + +The second image shows a preview of the downloaded file. This could be any file you place within assets if you need to test a specific file. + +Tester UI with no preview +Tester UI with preview +Tester UI with preview + ## Quick Start Quick start to launch all projects both web and server. ```sh npm install +npm run generate-assets nx run-many -t serve ``` -- Web: http://localhost:4200 -- Server http://localhost:3333 +- Web: +- Server For android make sure to rebind ports. diff --git a/apps/web/src/app/app.tsx b/apps/web/src/app/app.tsx index 5fe49f3..113db36 100644 --- a/apps/web/src/app/app.tsx +++ b/apps/web/src/app/app.tsx @@ -384,7 +384,6 @@ export function App() { Base64 Preview Image Generated base 64 diff --git a/docs/images/browser-link-tester-large.png b/docs/images/browser-link-tester-large.png new file mode 100644 index 0000000..70467d3 Binary files /dev/null and b/docs/images/browser-link-tester-large.png differ diff --git a/docs/images/browser-link-tester-preview.png b/docs/images/browser-link-tester-preview.png new file mode 100644 index 0000000..172927e Binary files /dev/null and b/docs/images/browser-link-tester-preview.png differ diff --git a/docs/images/browser-link-tester-with-image-resolved.png b/docs/images/browser-link-tester-with-image-resolved.png new file mode 100644 index 0000000..c123f41 Binary files /dev/null and b/docs/images/browser-link-tester-with-image-resolved.png differ