{"_id":"@memfoldai/tiptap-search-and-replace","_rev":"2-d912337ae3089067acd562732a2d7956","name":"@memfoldai/tiptap-search-and-replace","dist-tags":{"latest":"0.2.0"},"versions":{"0.2.0":{"name":"@memfoldai/tiptap-search-and-replace","version":"0.2.0","keywords":["tiptap-search-and-replace-extension","tiptap","tiptap-search-and-replace","wysiwyg","text editor","prosemirror"],"author":{"url":"github: sereneinserenade","name":"Jeet Mandaliya"},"_id":"@memfoldai/tiptap-search-and-replace@0.2.0","maintainers":[{"name":"nischithshadagopanmn","email":"nischith@memfold.ai"}],"homepage":"https://github.com/memfoldai/tiptap-search-and-replace#readme","bugs":{"url":"https://github.com/memfoldai/tiptap-search-and-replace/issues"},"dist":{"shasum":"99642a0c528ca3465b6e6565d7a0c1bd308a9994","tarball":"https://registry.npmjs.org/@memfoldai/tiptap-search-and-replace/-/tiptap-search-and-replace-0.2.0.tgz","fileCount":17,"integrity":"sha512-y3PpuPqHMlkXXmQeSomAPqCGJflx6X7f62pEbHqFCwW3FX2csCJGHzRdwGJLC4L4OXDH30+50HhQJekUN1rn3Q==","signatures":[{"sig":"MEUCIFxedx6+dx4tIzSIIa8y6XhaEQX5HIzwoGzLqNnQS37qAiEAkABpy+xYsqyppCgg8at5MOEUm1P2laExP7utquCRdCo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":50704},"main":"dist/index.cjs.js","types":"dist/index.d.ts","module":"dist/index.js","funding":{"url":"https://github.com/sponsors/sereneinserenade","type":"individual"},"gitHead":"12ef139ccfb1f33f2c4a9c9ba456fc6e334ab721","scripts":{"dev":"npm run clean && rollup -c -w","build":"npm run clean && rollup -c","clean":"rm -rf dist"},"_npmUser":{"name":"nischithshadagopanmn","email":"nischith@memfold.ai"},"repository":{"url":"git+https://github.com/memfoldai/tiptap-search-and-replace.git","type":"git"},"_npmVersion":"10.9.2","description":"Tiptap Extension for adding comments","directories":{},"_nodeVersion":"22.14.0","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"rollup":"^3.17.3","@tiptap/pm":"^3.0.0","typescript":"^4.9.5","@tiptap/core":"^3.0.0","@rollup/plugin-babel":"^6.0.3","@rollup/plugin-commonjs":"^24.0.1","rollup-plugin-sourcemaps":"^0.6.3","rollup-plugin-typescript2":"^0.34.1","rollup-plugin-auto-external":"^2.0.0"},"peerDependencies":{"@tiptap/pm":"^3.x.x","@tiptap/core":"^3.x.x"},"_npmOperationalInternal":{"tmp":"tmp/tiptap-search-and-replace_0.2.0_1754943116299_0.7559466088495728","host":"s3://npm-registry-packages-npm-production"}}},"time":{"created":"2025-08-11T20:11:56.206Z","modified":"2026-04-05T11:42:46.310Z","0.2.0":"2025-08-11T20:11:56.491Z"},"bugs":{"url":"https://github.com/memfoldai/tiptap-search-and-replace/issues"},"author":{"url":"github: sereneinserenade","name":"Jeet Mandaliya"},"homepage":"https://github.com/memfoldai/tiptap-search-and-replace#readme","keywords":["tiptap-search-and-replace-extension","tiptap","tiptap-search-and-replace","wysiwyg","text editor","prosemirror"],"repository":{"url":"git+https://github.com/memfoldai/tiptap-search-and-replace.git","type":"git"},"description":"Tiptap Extension for adding comments","maintainers":[{"email":"kunal@memfold.ai","name":"kunal-memfold"},{"email":"nischith@memfold.ai","name":"nischithshadagopanmn"}],"readme":"# Tiptap 3 Search and Replace\n\nSearch and Replace extension for [Tiptap 3](https://tiptap.dev). Published to npm as `@memfoldai/tiptap-search-and-replace`.\n\nA ⭐️ to the repo if you 👍 / ❤️  what I'm doing would be much appreciated. If you're using this extension and making money from it, it'd be very kind of you to [:heart: Sponsor me](https://github.com/sponsors/sereneinserenade). If you're looking for a **dev to work you on your project's Rich Text Editor** with or as **a frontend developer, [DM me on Discord/Twitter/LinkedIn](https://github.com/sereneinserenade)👨‍💻🤩**.\n\nI've made a bunch of extensions for Tiptap, some of them are **Google Docs like Commenting**, **Resize image and Videos**, **LanguageTool integration** with tiptap. You can check it our here https://github.com/sereneinserenade#a-glance-of-my-projects .\n\n# Live Demo\n\nTry it out live at https://sereneinserenade.github.io/tiptap-search-and-replace, and/or take a look at a demo-video below.\n\n<details> \n  <summary> <b>demo-video</b> </summary>\n  \nhttps://user-images.githubusercontent.com/45892659/163356581-5fd38888-4e29-41d9-b64f-d17948ef7a16.mov\n</details>\n\n## How to use\n\n> **Note**: This repository and demo target Tiptap v3. Use versions `^3.x` for `@tiptap/*` packages. Demo imports the local extension from `src/searchAndReplace.ts`.\n\n**Ideally you should keep track of these states in your code, but if you absolutely need to read the `searchTerm` and `replaceTerm` from extension, here's the code.**\n```ts\nconst searchTerm: string = editor.storage.searchAndReplace.searchTerm\nconst replaceTerm: string = editor.storage.searchAndReplace.replaceTerm\n```\n\n\nI've published it as an npm package so you can either directly install it, \n \n<details>\n  <summary> with NPM </summary>\n\n```\nnpm i @memfoldai/tiptap-search-and-replace\n```\n</details>\n<details>\n  <summary> with Yarn </summary>\n\n```\nyarn add @memfoldai/tiptap-search-and-replace\n```\n</details>\n\n### Here are example implementations in Vue and React\n\n<details>\n  <summary> Vue </summary>\n\n```ts\nimport { Editor } from \"@tiptap/core\";\nimport { SearchNReplace } from \"./path/to/search-n-replace.ts/\";\n\nconst editor = new Editor({\n  content: \"<p>Example Text</p>\",\n  extensions: [\n    SearchNReplace.configure({\n      searchResultClass: \"search-result\", // class to give to found items. default 'search-result'\n      caseSensitive: false, // no need to explain\n      disableRegex: false, // also no need to explain\n    }),\n  ],\n});\n\nconst searchTerm = ref<string>(\"replace\");\n\nconst replaceTerm = ref<string>(\"astonishing\");\n\n// you can use the commands provided by SearchNReplace extension to update the values of search and replace terms.\nconst updateSearchReplace = () => {\n  if (!editor.value) return;\n  editor.value.commands.setSearchTerm(searchTerm.value);\n  editor.value.commands.setReplaceTerm(replaceTerm.value);\n};\n```\n</details>\n  \n<details>\n  <summary> React </summary>\n\n```ts\nimport { Editor } from \"@tiptap/core\";\nimport { SearchNReplace } from \"./path/to/search-n-replace.ts/\";\n\nconst editor = new Editor({\n  content: \"<p>Example Text</p>\",\n  extensions: [\n    SearchNReplace.configure({\n      searchResultClass: \"search-result\", // class to give to found items. default 'search-result'\n      caseSensitive: false, // no need to explain\n      disableRegex: false, // also no need to explain\n    }),\n  ],\n});\n\nconst searchTerm = useState<string>(\"replace\");\n\nconst replaceTerm = useState<string>(\"astonishing\");\n\n// you can use the commands provided by SearchNReplace extension to update the values of search and replace terms.\nconst updateSearchReplace = () => { // you can probably use `useCallback` hook)\n  if (!editor.value) return;\n  editor.value.commands.setSearchTerm(searchTerm.value);\n  editor.value.commands.setReplaceTerm(replaceTerm.value);\n};\n```\n</details>\n\n\n\n## Contributing\n\nShow your ❤️ by ⭐️ing this repository! It means a lot.\n\nClone the repo, do something, make a PR(or not). You know what's the drill. Looking forward to your PRs, you amazing devs.\n\n## Awesome peeps, who've starred this repo 🚀! Thank you!\n[![Stargazers repo roster for @sereneinserenade/tiptap-search-and-replace](https://reporoster.com/stars/dark/sereneinserenade/tiptap-search-and-replace)](https://github.com/sereneinserenade/tiptap-search-and-replace/stargazers)\n\n---\n\n<details>\n  <summary> Stuff that nobody really cares about </summary>\n\n  # Vue 3 + Vite\n\n  This template should help get you started developing with Vue 3 in Vite. The template uses Vue 3 `<script setup>` SFCs, check out the [script setup docs](https://v3.vuejs.org/api/sfc-script-setup.html#sfc-script-setup) to learn more.\n\n  ## Recommended IDE Setup\n\n  - [VS Code](https://code.visualstudio.com/) + [Volar](https://marketplace.visualstudio.com/items?itemName=johnsoncodehk.volar)\n</details>\n","readmeFilename":"README.md"}