A sample of developing a custom Obsidian TextFileView plugin, which includes customizing TextFileView, file operation, auto-saving, unload handling, SASS, and other required code logic.
-
Open a terminal window and change the project directory to the plugins directory.
cd path/to/vault/.obsidian/plugins
-
Clone the sample plugin using Git.
git clone [email protected]:korbinzhao/obsidian-textfileview-plugin-sample.git
-
Navigate to the plugin directory.
cd obsidian-textfileview-plugin-sample
-
Install dependencies
yarn
-
Compile the source code
yarn start
To load a plugin in Obsidian, you first need to enable it.
- In Obsidian, open Settings.
- In the side menu, select Community plugins.
- Select Turn on community plugins.
- Under Installed plugins, enable the Sample Plugin by selecting the toggle button next to it. You're now ready to use the plugin in Obsidian. Next, we'll make some changes to the plugin.
Visit Obsidian Develop Docs for more development guide.
Like this sample, feed my cat. :point_right: Feed my cat