diff --git a/.changeset/flat-trees-drive.md b/.changeset/flat-trees-drive.md
new file mode 100644
index 00000000..1b47b4db
--- /dev/null
+++ b/.changeset/flat-trees-drive.md
@@ -0,0 +1,5 @@
+---
+'@svelte-put/preprocess-external-link': patch
+---
+
+add some basic info at README.md
diff --git a/packages/preprocess-external-link/README.md b/packages/preprocess-external-link/README.md
index 21f044f4..2422c969 100644
--- a/packages/preprocess-external-link/README.md
+++ b/packages/preprocess-external-link/README.md
@@ -1,10 +1,10 @@
-# `@svelte-put/preprocess-inline-svg`
+# `@svelte-put/preprocess-external-link`
[![npm.badge]][npm] [![bundlephobia.badge]][bundlephobia] [![docs.badge]][docs]
-Svelte preprocessor for inlining static svg at build time
+Svelte preprocessor for adding attributes to anchor tags that point to external domains.
@@ -21,65 +21,46 @@ This package is part of the [@svelte-put][github.monorepo] family. For contribut
Given this `svelte.config.js`
```javascript
-import inlineSvg from '@svelte-put/preprocess-inline-svg';
+import externalLink from '@svelte-put/preprocess-external-link';
/** @type {import('@sveltejs/kit').Config} */
const config = {
preprocess: [
- inlineSvg([
- {
- directories: 'src/assets/icons',
- attributes: {
- class: 'icon',
- width: '20',
- height: '20',
- },
- },
- {
- directories: 'src/assets/pictograms',
- },
- ]),
+ externalLink(['your-domain.com', 'your-other-domain.com']),
// other preprocessors
],
};
export default config;
```
-and the asset files as follow
-
-```tree
-src/assets
- |
- |-- icons
- |-- svelte.svg
- |
- |-- google
- |-- arrow-right.svg
- |-- simpleicons
- |-- github.svg
- |
- |-- pictograms
- |-- diagram.svg
-```
-
-We can now do
+and the following input markup
-```html
-
-
+```svelte
+
-
-
-
-
+
+Internal Path
+Internal Path
+Internal Path
-
-
+
+Svelte
+Svelte
+```
-
-
+will output
-
+```html
+
+Internal Path
+Internal Path
+Internal Path
+
+
+Svelte
+Svelte
```
## [Changelog][github.changelog]
@@ -87,14 +68,14 @@ We can now do
[github.monorepo]: https://github.com/vnphanquang/svelte-put
-[github.changelog]: https://github.com/vnphanquang/svelte-put/blob/main/packages/preprocess-inline-svg/CHANGELOG.md
+[github.changelog]: https://github.com/vnphanquang/svelte-put/blob/main/packages/preprocess-external-link/CHANGELOG.md
[github.issues]: https://github.com/vnphanquang/svelte-put/issues?q=
-[npm.badge]: https://img.shields.io/npm/v/@svelte-put/preprocess-inline-svg
-[npm]: https://www.npmjs.com/package/@svelte-put/preprocess-inline-svg
-[bundlephobia.badge]: https://img.shields.io/bundlephobia/minzip/@svelte-put/preprocess-inline-svg?label=minzipped
-[bundlephobia]: https://bundlephobia.com/package/@svelte-put/preprocess-inline-svg
-[docs]: https://svelte-put.vnphanquang.com/docs/preprocess-inline-svg
+[npm.badge]: https://img.shields.io/npm/v/@svelte-put/preprocess-external-link
+[npm]: https://www.npmjs.com/package/@svelte-put/preprocess-external-link
+[bundlephobia.badge]: https://img.shields.io/bundlephobia/minzip/@svelte-put/preprocess-external-link?label=minzipped
+[bundlephobia]: https://bundlephobia.com/package/@svelte-put/preprocess-external-link
+[docs]: https://svelte-put.vnphanquang.com/docs/preprocess-external-link
[docs.badge]: https://img.shields.io/badge/-Docs%20Site-blue