Official, comprehensive list of `config.edn` options

Logseq devs: it would be very helpful if an official, comprehensive, always-up-to-date list of config.edn options could be maintained.

The need for this should be fairly obvious :slight_smile:

Discord message.

Thanks very much!

Fantastic request and completely agree. I always get the feeling I am missing some cool settings when I see messages about the .edn

1 Like

Closest thing we have at the moment is this logseq/config.edn at master Ā· logseq/logseq Ā· GitHub

1 Like

@Aryan, thanks, that is very helpful, and could be what we are looking for. Some questions:

  • How comprehensive would you say that template is?
  • How up to date is it kept?
  • If I start a new graph, will the config.edn be a exact copy of that template? (That way, users donā€™t have to hunt for config.edn options and documentation)
  • I see :feature/enable-block-timestamps? false for example doesnā€™t have documentation in comments. Would be great if that could be added.

Thanks again.

1 Like
  1. fairly comprehensive, it has most if not all
  2. updated almost every time a new option is added
  3. It will be the same, yes
  4. Definitely would be useful
1 Like

copy pasting a related post from discord (01/03/2022) :

The config.edn template workflow has always bothered me : newer settings introduced with a new logseq version canā€™t be seen in existing graphs as the config.edn canā€™t be updated automatically.

Currently the only way to ā€˜updateā€™ a config.edn with new settings is by checking changelogs, then manually comparing with the current github source, or by creating a new empty graph to generate a new default config.edn, then compare/edit.

There should be a way to automatically get new available setting/config options after an update.

short-term / medium-term proposal :

Maybe there should be a separate config.edn and a config-user.edn similar to style.css vs custom.css ? or similar to how config files are set-up in sublimeText or VSCode (default settings, user settings, workspace settings) :

  • the default config.edn would contain all available options + comments and gets updated automatically, user is not supposed to edit it manually.
  • the config-user.edn would override contents of config.edn and contains specific user-settings that differ from the default of config.edn, journal queries, etcā€¦

I realize this is only a short-term/medium-term solution that is not great in terms of user-friendliness/ux,

long term / ideal solution :

ideally a GUI should handle all options, with maybe an additional freeform textarea for advanced users who want to manually add specific flags/overrules (similar to a custom.css textarea in most website builders) .
Users should not have to edit config.edn at all, only add additional settings via the textarea.

6 Likes

Unfortunately the list does not include DWIM settings:

:dwim/settings
{
   :admonition&src?  true
   :markup?          false
   :block-ref?       true
   :page-ref?        true
   :properties?      true
   :list?            true
}
1 Like

Not official, but I manually created this: dotfiles/config.edn at master Ā· kaushalmodi/dotfiles Ā· GitHub

The default configs are commented out.

4 Likes

@noted Hi. logseq/config.edn at master Ā· logseq/logseq Ā· GitHub is the comprehensive list of config options. See https://docs.logseq.com/#/page/config.edn for more more documentation on configuration

@Ed_Nico Good catch. Iā€™ve opened Chore: Document config introduced in #2975 by logseq-cldwalker Ā· Pull Request #6484 Ā· logseq/logseq Ā· GitHub to document this missing config

@cannibalox Thatā€™s an insightful comment but would be better in Store config.edn modifications in a separate file . Iā€™ll be commenting over there for how to keep up to date with config options

1 Like

@cldwalker I scraped the logseq discord server messages to try to find all mentions of configuration options. I have cleaned up the list, but I expect that there are many false positives.
Note that this list will contain a combination of:

  • global graph config
  • local graph config
  • page config
  • block config

None of these config options exist in the config template, as I already filtered them out.

Iā€™ll need some time and assistance to split these into the categories mentioned above and remove the false positive ones.

:block/alias
:block/anchor
:block/block-ref
:block/block-refs-count
:block/bottom
:block/collapsed
:block/content
:block/content-max-length
:block/created-at
:block/date
:block/deadline
:block/file
:block/format
:block/heading
:block/heading-level
:block-hidden-properties
:block-id
:block/journal
:block/journal-day
:block/keys
:block/last-modified-at
:block/left
:block/level
:block/markers
:block/meta
:block/name
:block/namespace
:block/open
:block/order
:block/original-name
:block/page
:block/parent
:block/parents
:block/path-ref-pages
:block/path-refs
:block/pre-block
:block/priority
:block/properties
:block/properties-order
:block/property
:block/property-name
:block/props
:block/ref
:block/refs
:block/ref-pages
:block/repeated
:block/repo
:block/scheduled
:block/size
:block/string
:block/tag
:block/tags
:block/text-align
:block/title
:block/top
:block/type
:block/uid
:block/unordered
:block/updated-at
:block/uuid

:breadcrumb-show

:current-page

:custom-css

:custom-css-url

:custom-relation

:d-before
:d-before-ms
:d-after
:d-after-ms

:data-href
:data-ref
:data-text
:data-uuid
:date-formatter
:date-int

:date-picker/next-day
:date-picker/next-week
:date-picker/prev-day
:date-picker/prev-week


:db/id
:db/ident
:db/restore
:db/restore-failed

:default-home
:default-queries
:default-templates

:dwim/settings

:editor/action
:editor/backspace
:editor/clear-block
:editor/copy-embed
:editor/cursor-back
:editor/cursor-forward
:editor/cycle-todo
:editor/delete
:editor/down
:editor/end-of-block
:editor/escape-editing
:editor/extra-codemirror-options
:editor/highlight
:editor/input
:editor/insert-link
:editor/left
:editor/move-block-down
:editor/move-block-up
:editor/move-cursor-to-end
:editor/new-block
:editor/new-line
:editor/open-edit
:editor/right
:editor/save
:editor/up

:end-of-today-ms

:export/bullet-indentation

:git-auto-push
:git/push-error
:git/sha
:git/url

:go/backward
:go/electron-find-in-page
:go/forward
:go/journals
:go/today

:journal/file-name-format
:journal-from-scheduled
:journal/page-title-format
:journals-directory
:journals-length

:last-child

:last-of-type

:last-pattern

:level-limit

:lineNumbers

:lineWrapping

:local_native-fs

:local/root

:metadata

:metadata-exceptions

:name/favorites

:name-of-properties

:Namespace/Attribute

:outliner/block-title-collapse-enabled

:page/create

:page/journal

:page/journal-day

:page-name-order

:page/properties

:page-ref

:pages-directory

:page/tags

:page/updated-at

:parent-block-uuid

:parser-worker

:property-pages/enabled

:property-pages/excludelist

:property-values-allow-links-and-text

:publishing/all-pages-public

:quick-capture-template

:ref/default-open-blocks-level

:ref/linked-references-collapsed-threshold

:ref/linked-references-collapse-enabled

:result-transform

:right-side-bar/flashcards

:shortcut/doc-mode-enter-for-new-block

:shortcuts

:srs/initial-interval

:srs/learning-fraction

:start-of-today-ms

:start-of-week

:text-align

:text/css

:ui/enable-tooltip

:ui/show-empty-bullets

:ui/toggle-settings

:ui/wide-mode

all config options defined in the config.edn template:

 :meta/version 1
 :preferred-format ""
 :preferred-workflow :now
 :hidden []
 :default-templates {:journals ""}
 :ui/enable-tooltip? true
 :ui/show-brackets? true
 :ui/show-full-blocks? false
 :feature/enable-block-timestamps? false
 :feature/enable-search-remove-accents? true
 :feature/enable-journals? true
 :feature/enable-flashcards? true
 :feature/disable-scheduled-and-deadline-query? true
 :start-of-week 6
 :custom-css-url "@import url('https://cdn.jsdelivr.net/gh/dracula/logseq@master/custom.css');"
 :export/bullet-indentation :tab
 :publishing/all-pages-public? true
 :default-home {:page "home" :sidebar ["page a" "page b"]}
 :pages-directory "your-directory"
 :journals-directory "your-directory"
 :org-mode/insert-file-link? true
 :shortcuts {}
 :shortcut/doc-mode-enter-for-new-block? false
 :block/content-max-length 10000
 :ui/show-command-doc? true
 :ui/show-empty-bullets? false
 :query/views {:pprint (fn [r] [:pre.code (pprint r)])}
 query/result-transforms {:sort-by-priority (fn [result] (sort-by (fn [h] (get h :block/priority "Z")) result))} 
 :default-queries {}
 :commands [] 
 :outliner/block-title-collapse-enabled? false
 :macros {}
 :ref/default-open-blocks-level 2
 :ref/linked-references-collapsed-threshold 50
 :favorites []
 :srs/learning-fraction 0.5
 :srs/initial-interval 4
 :block-hidden-properties #{:created-at :updated-at}
 :block-hidden-properties #{}
 :property-pages/enabled? true
 :property-pages/excludelist {:duration :author}
 :property/separated-by-commas #{:alias :tags}
 :ignored-page-references-keywords #{"author" "startup"}
 :logbook/settings
 :mobile/photo {}
 :mobile {:gestures/disabled-in-block-with-tags ["kanban"]}
 :editor/extra-codemirror-options {:keyMap "emacs" :lineWrapping true}
 :editor/logical-outdenting? true
 :editor/preferred-pasting-file? true
 :quick-capture-templates {}
 :quick-capture-options {:insert-today? false :redirect-page? false}
 :file-sync/ignore-files []
 :dwim/settings {}
 :file/name-format :triple-lowbar
2 Likes

Thanks to the tip from @cldwalker

I believe I got the complete list by parsing the source code using Regex;
Mainly state.cljs and common_config.cljs.

@cldwalker can you please confirm the value format of:

  • :editor/command-trigger :string
  • :shell/command-allowlist [:vector :string]
  • :arweave/gateway :string
  • :user-config :string

List of config options and their expected values:

:meta/version :int

:preferred-format [:or :keyword :string]
:preferred-workflow [:enum :now :todo]

:hidden [:vector :string]

:default-templates [:map-of [:enum :journals] :string]

:ui/enable-tooltip? :boolean
:ui/show-full-blocks? :boolean

:feature/enable-block-timestamps? :boolean
:feature/enable-search-remove-accents? :boolean
:feature/enable-journals? :boolean
:feature/enable-flashcards? :boolean
:feature/disable-scheduled-and-deadline-query? :boolean
:feature/enable-whiteboards? :boolean

:org-mode/insert-file-link? :boolean

:start-of-week [:enum 0 1 2 3 4 5 6]

:custom-css-url :string
:custom-js-url :string

:export/bullet-indentation [:enum :eight-spaces :four-spaces :two-spaces :tab]

:publishing/all-pages-public? :boolean
:publishing/enable-editing? :boolean

:arweave/gateway :string

:default-home [:map [:page {:optional true} :string] [:sidebar {:optional true} [:or :string [:vector :string]]]]
:pages-directory :string
:journals-directory :string
:whiteboards-directory :string

:org-mode/insert-file-link? :boolean

:shortcuts [:map-of :keyword [:or :string [:vector :string]]]
:shortcut/doc-mode-enter-for-new-block? :boolean

:block/content-max-length :int

:ui/show-command-doc? :boolean
:ui/show-empty-bullets? :boolean
:ui/show-full-blocks? :boolean

:query/views [:map-of :keyword [:sequential any?]]
:query/result-transforms [:map-of :keyword [:sequential any?]]

:default-queries [:map [:journals [:vector :map]]]

:commands [:vector [:tuple :string :string]]

:outliner/block-title-collapse-enabled? :boolean

:macros [:map-of :string :string]

:ref/default-open-blocks-level :int
:ref/linked-references-collapsed-threshold :int

:favorites [:vector :string]

:srs/learning-fraction float?
:srs/initial-interval :int

:block-hidden-properties [:set :keyword]

:property-pages/enabled? :boolean
:property-pages/excludelist [:set :keyword]

:property/separated-by-commas [:set :keyword]

:ignored-page-references-keywords [:set :keyword]

:logbook/settings :map

:mobile/photo [:map [:allow-editing? {:optional true} :boolean] [:quality {:optional true} :int]]

:mobile [:map [:gestures/disabled-in-block-with-tags {:optional true} [:vector :string]]]

:editor/extra-codemirror-options :map
:editor/logical-outdenting? :boolean
:editor/preferred-pasting-file? :boolean
:editor/command-trigger :string

:quick-capture-templates [:map [:text {:optional true} :string] [:media {:optional true} :string]]
:quick-capture-options [:map [:insert-today? {:optional true} :boolean] [:redirect-page? {:optional true} :boolean]]

:file-sync/ignore-files [:vector :string]

:dwim/settings [:map-of :keyword :boolean]

:file/name-format [:enum :legacy :triple-lowbar]

:shell/command-allowlist [:vector :string]

:journal/page-title-format :string
:journal/file-name-format :string

:date-formatter :string

flashcards? :boolean

:scheduled/future-days :int

:start-of-week [:enum 0 1 2 3 4 5 6]

:user-config :string

  • TODO: make sure all are documented
  • TODO: update the confing template
  • TODO: refactor common_config.cljs to match the order of state.cljs
1 Like

according to :point_up_2: :date-formatter is deprecated

1 Like

Here is a PR that adds the missing configurations to the config.edn template:

Happy to announce that after a lot of work and effort, we now have a comprehensive well document and formatted config.edn template.

Thanks to everyone who helped.