create-ampless 1.0.0-alpha.63 → 1.0.0-alpha.66
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js
CHANGED
|
@@ -1757,7 +1757,9 @@ var AMPLESS_PACKAGES = /* @__PURE__ */ new Set([
|
|
|
1757
1757
|
"@ampless/plugin-rss",
|
|
1758
1758
|
"@ampless/plugin-webhook",
|
|
1759
1759
|
"@ampless/plugin-og-image",
|
|
1760
|
-
"@ampless/plugin-analytics-ga4"
|
|
1760
|
+
"@ampless/plugin-analytics-ga4",
|
|
1761
|
+
"@ampless/plugin-gtm",
|
|
1762
|
+
"@ampless/plugin-plausible"
|
|
1761
1763
|
]);
|
|
1762
1764
|
var AMPLESS_MANAGED_SCRIPTS = /* @__PURE__ */ new Set([
|
|
1763
1765
|
"sandbox",
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import { defineConfig } from 'ampless'
|
|
2
2
|
import seoPlugin from '@ampless/plugin-seo'
|
|
3
3
|
import rssPlugin from '@ampless/plugin-rss'
|
|
4
|
+
// import analyticsGa4Plugin from '@ampless/plugin-analytics-ga4'
|
|
5
|
+
// import gtmPlugin from '@ampless/plugin-gtm'
|
|
6
|
+
// import plausiblePlugin from '@ampless/plugin-plausible'
|
|
4
7
|
// import webhookPlugin from '@ampless/plugin-webhook'
|
|
5
8
|
// import ogImagePlugin, { loadFontFromUrl } from '@ampless/plugin-og-image'
|
|
6
9
|
|
|
@@ -68,6 +71,30 @@ export default defineConfig({
|
|
|
68
71
|
// ],
|
|
69
72
|
// }),
|
|
70
73
|
//
|
|
74
|
+
// Google Analytics 4. Once registered here, the measurement ID can be
|
|
75
|
+
// edited from `/admin/plugins` without a redeploy — the constructor
|
|
76
|
+
// value below is just the initial default. Pass an empty string to
|
|
77
|
+
// disable the GA tag entirely. See packages/ampless/docs/plugin-author-guide.md.
|
|
78
|
+
//
|
|
79
|
+
// analyticsGa4Plugin({
|
|
80
|
+
// measurementId: '', // 'G-XXXXXXXX' to enable
|
|
81
|
+
// }),
|
|
82
|
+
//
|
|
83
|
+
// Google Tag Manager. Like GA4, the container ID is editable from
|
|
84
|
+
// `/admin/plugins` after deploy. Tags fire via GTM's own trigger model.
|
|
85
|
+
//
|
|
86
|
+
// gtmPlugin({
|
|
87
|
+
// containerId: '', // 'GTM-XXXXXXX' to enable
|
|
88
|
+
// }),
|
|
89
|
+
//
|
|
90
|
+
// Plausible Analytics (privacy-focused, typically no cookie consent
|
|
91
|
+
// required). `domain` matches the registered Plausible site.
|
|
92
|
+
// `scriptUrl` defaults to plausible.io; override for self-hosted.
|
|
93
|
+
//
|
|
94
|
+
// plausiblePlugin({
|
|
95
|
+
// domain: '', // 'example.com' to enable
|
|
96
|
+
// }),
|
|
97
|
+
//
|
|
71
98
|
// Per-post OG images: SNS crawlers hit `/og/<slug>` and we render
|
|
72
99
|
// a JSX card → PNG via Next.js `ImageResponse`. Requires at least one
|
|
73
100
|
// font — ship a .ttf from your CDN or `/public` directory.
|
|
@@ -467,6 +467,8 @@ it('admin が空文字保存した場合は空配列', () => {
|
|
|
467
467
|
参考実装:
|
|
468
468
|
|
|
469
469
|
- [`packages/plugin-analytics-ga4`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-analytics-ga4) — descriptor ベース、Phase 2 settings
|
|
470
|
+
- [`packages/plugin-gtm`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-gtm) — `publicHead`(ローダーインラインスクリプト)+ `publicBodyEnd`(`<noscript>` iframe フォールバック)を両方使用、コンテナ ID は admin 編集可能
|
|
471
|
+
- [`packages/plugin-plausible`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-plausible) — `data-*` attrs 付きの単一 `<script>` descriptor、`required` な URL field(self-hosted Plausible 上書き対応)
|
|
470
472
|
- [`packages/plugin-rss`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-rss) — trusted、非同期 hooks + `writePublicAsset`
|
|
471
473
|
- [`packages/plugin-seo`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-seo) — `metadata()` + `siteMetadata()`
|
|
472
474
|
- [`packages/plugin-webhook`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-webhook) — untrusted hook + 外向き HTTP
|
|
@@ -575,6 +575,8 @@ a normal npm package:
|
|
|
575
575
|
Worked examples to crib from:
|
|
576
576
|
|
|
577
577
|
- [`packages/plugin-analytics-ga4`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-analytics-ga4) — descriptor-based, Phase 2 settings.
|
|
578
|
+
- [`packages/plugin-gtm`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-gtm) — uses both `publicHead` (loader inline script) and `publicBodyEnd` (`<noscript>` iframe fallback) with the container ID admin-edited.
|
|
579
|
+
- [`packages/plugin-plausible`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-plausible) — single `<script>` descriptor with `data-*` attrs and a required URL field (self-hosted Plausible override).
|
|
578
580
|
- [`packages/plugin-rss`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-rss) — trusted, async event hooks + `writePublicAsset`.
|
|
579
581
|
- [`packages/plugin-seo`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-seo) — `metadata()` + `siteMetadata()`.
|
|
580
582
|
- [`packages/plugin-webhook`](https://github.com/heavymoons/ampless/tree/main/packages/plugin-webhook) — untrusted hook with outbound HTTP.
|
|
@@ -25,7 +25,10 @@
|
|
|
25
25
|
"@tiptap/pm": "^3.23.6",
|
|
26
26
|
"@tiptap/react": "^3.23.6",
|
|
27
27
|
"@tiptap/starter-kit": "^3.23.6",
|
|
28
|
+
"@ampless/plugin-analytics-ga4": "^0.2.0-alpha.1",
|
|
29
|
+
"@ampless/plugin-gtm": "^0.1.1-alpha.0",
|
|
28
30
|
"@ampless/plugin-og-image": "^0.2.0-alpha.18",
|
|
31
|
+
"@ampless/plugin-plausible": "^0.1.1-alpha.0",
|
|
29
32
|
"@ampless/plugin-rss": "^0.2.0-alpha.18",
|
|
30
33
|
"@ampless/plugin-seo": "^0.2.0-alpha.18",
|
|
31
34
|
"@ampless/plugin-webhook": "^0.2.0-alpha.18",
|