Notes about math, research, and more.

How to do transclusion:

  1. Create the following line “#+transclude: transclusion_a.html
  2. Then, with cursor on that line run “M-x org-transclusion-add”
  3. Could also do org-transclusion-add-all

This will then bring in the contents of the other file.

The transcluded input is immutable

With LaTeX

The above will render properly in LaTeX as long as I have the following in init.el somewhere:

(defun my-org-export-before-processing-hook (backend) “Hook to run before export, specifically for transclude” (when (eq backend ’latex) (org-transclusion-add-all))) (add-hook ’org-export-before-processing-hook #’my-org-export-before-processing-hook)

This says that before exporting to LaTeX, run org-transclusion-add-all.

Examples using different filters

Attempting transclusion here:

Here we do with keyward :only-contents

Here with :exclude-elements “drawer keyward”

Here with :lines 5- (does everything line 5 onward. Could also do :lines 5-8)

Can not use the following as org-publish cant handle the fuzzy search transclude: transclusion_a.html#org7697964