diff --git a/guide.md b/guide.md index 6834c6c080..abb8e0cee2 100644 --- a/guide.md +++ b/guide.md @@ -49,8 +49,8 @@ Use browser ESM assets from a CDN: href="https://cdn.rrweb.com/replay/current/dist/style.css" /> ``` @@ -329,7 +330,7 @@ the CDN: href="https://cdn.rrweb.com/replay/current/dist/style.css" /> ``` +Use `.min.js` for production; switch to the unminified `.js` sibling when +debugging. + #### Control the replayer by API ```js @@ -410,10 +414,13 @@ Browser without bundler (ESM): href="https://cdn.rrweb.com/rrweb-player/current/style.css" /> ``` +Use `.min.js` for production; switch to the unminified `.js` sibling when +debugging. + Legacy direct ` ``` @@ -323,7 +324,7 @@ import '@rrweb/replay/dist/style.css'; href="https://cdn.rrweb.com/replay/current/dist/style.css" /> ``` +生产环境请使用 `.min.js`;调试时可改用未压缩的 `.js` 同级文件。 + #### 使用 API 控制回放 ```js @@ -402,10 +405,12 @@ import 'rrweb-player/dist/style.css'; href="https://cdn.rrweb.com/rrweb-player/current/style.css" /> ``` +生产环境请使用 `.min.js`;调试时可改用未压缩的 `.js` 同级文件。 + Legacy 直接 ` ``` Use `current` for the latest stable release, or pin an exact version such as -`https://cdn.rrweb.com/record/2.0.0/dist/record.js` for immutable -production URLs. +`https://cdn.rrweb.com/record/2.0.0/dist/record.min.js` for immutable +production URLs. Use `.min.js` for production; the unminified `.js` sibling +remains useful for debugging. ### 3) Legacy Direct ` ``` Use `current` for the latest stable release, or pin an exact version such as -`https://cdn.rrweb.com/replay/2.0.0/dist/replay.js` for immutable -production URLs. +`https://cdn.rrweb.com/replay/2.0.0/dist/replay.min.js` for immutable +production URLs. Use `.min.js` for production; the unminified `.js` sibling +remains useful for debugging. ### 3) Legacy Direct ` ``` Use `current` for the latest stable release, or pin an exact version such as -`https://cdn.rrweb.com/rrweb-player/2.0.0/rrweb-player.js` for immutable -production URLs. See the [CDN assets docs](https://rrweb.com/docs/cloud/cdn-assets) -for the full URL shape and catalog. +`https://cdn.rrweb.com/rrweb-player/2.0.0/rrweb-player.min.js` for immutable +production URLs. Use `.min.js` for production; the unminified `.js` sibling +remains useful for debugging. See the +[CDN assets docs](https://rrweb.com/docs/cloud/cdn-assets) for the full URL +shape and catalog. ### 3) Legacy Direct ` ``` Use `current` for the latest stable release, or pin exact versions such as -`https://cdn.rrweb.com/record/2.0.0/dist/record.js` and -`https://cdn.rrweb.com/replay/2.0.0/dist/replay.js` for immutable -production URLs. +`https://cdn.rrweb.com/record/2.0.0/dist/record.min.js` and +`https://cdn.rrweb.com/replay/2.0.0/dist/replay.min.js` for immutable +production URLs. Use `.min.js` for production; the unminified `.js` sibling +remains useful for debugging. ### 3) Legacy Direct `