Code Monkey home page Code Monkey logo

templater-plugins's Introduction

Plugins/ Functions for Obsidian

Prerequisites

  • Installed the Templater plugin in your vault.
  • Created directory "Templates" for storing your templates to use with Templater.
  • Configured your Templater plugin settings for template folder location "Templates".
  • Created a subdirectory "Templates/Functions" and added js-file of mine.
  • Configured your Templater plugin settings for User Script Functions to be under "Templates/Functions".

(You can call your folders however you want.)

General Usage of Templater

Creating a template

Add in any file in the template folder:

<%* tp.user.<user_function>() -%> if you want to dismiss the return value

OR

<% tp.user.<user_function>() %> if you want to print the return value in the file

(More specific usage instructions in the user script function section.)

Applying a template

Alt+E to show all applyable templates.

OR

Ctrl+P to open the command pallete and type "templater" and run the "Open Insert Template Model".

Both options open a dropdown to select a template. Select the one you need.

Documentations

  1. Official Obisidian
  2. Unofficial Obsidian
  3. Templater

The Obisidan docs "help" with stuff regarding app.workspace and app.vault. The Templater docs "help" with all tp related functions.

User Script Functions in this repository

log_template.js

Creates a daily note in the schema of "YYYY-MM-DD". If no folder exists for this month a log folder in the schema of "YYYY-MM" in your log folder is created. You can create a new note anywhere in the workspace and apply that template to it and if a daily note already exists, delete the new note, and open the existing daily note, otherwise move the new file to the monthly log folder and make this new note the daily note. Finally the daily note's tab is pinned.

Prerequisites: A folder where you keep your daily notes in. (Here: "Log".)

Usage: <%* tp.user.log_template(tp, "Log") -%>

templater-plugins's People

Contributors

haraldar avatar

Stargazers

Nikita Khutorni avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.