This plugin replaces \\(
and \\)
with $
and \\[
and \\]
with $$
on paste in Obsidian.
-
Download the Plugin:
- Clone or download the repository to your local machine.
-
Build the Plugin:
- Open a terminal in the plugin directory and run the following command to install dependencies:
npm install
- Build the plugin by running:
npm run build
- Open a terminal in the plugin directory and run the following command to install dependencies:
-
Load the Plugin in Obsidian:
- Copy the contents of the
dist
folder to your Obsidian plugins directory. This is usually located at:<vault>/.obsidian/plugins/obsidian-paste-tex-replacer/
- Ensure that the
main.js
,manifest.json
, andstyles.css
(if any) files are in the plugin directory.
- Copy the contents of the
-
Enable the Plugin:
- Open Obsidian and go to
Settings
>Community plugins
. - Click on
Browse
and search forPaste TeX Replacer
. - Enable the
Paste TeX Replacer
plugin.
- Open Obsidian and go to
To develop and test the plugin locally:
-
Start the Development Server:
- Run the following command to start the development server:
npm run dev
- Run the following command to start the development server:
-
Watch for Changes:
- The development server will watch for changes and rebuild the plugin automatically.
Once the plugin is enabled, it will automatically replace \\(
and \\)
with $
and \\[
and \\]
with $$
when you paste text into an Obsidian note.
To uninstall the plugin:
-
Disable the Plugin:
- Open Obsidian and go to
Settings
>Community plugins
. - Disable the
Paste TeX Replacer
plugin.
- Open Obsidian and go to
-
Remove the Plugin Files:
- Delete the
obsidian-paste-tex-replacer
folder from your Obsidian plugins directory.
- Delete the
This project is licensed under the MIT License.# obsidian-paste-tex-replacer