mirror of
https://github.com/lektor/lektor-website.git
synced 2025-02-20 14:30:38 +01:00
Merge branch 'master' into master
This commit is contained in:
commit
658fa1430b
@ -16,7 +16,7 @@ database. There are two types of source objects:
|
|||||||
* [Assets :ref](../asset/) which are files and directories from the
|
* [Assets :ref](../asset/) which are files and directories from the
|
||||||
`assets/` folder.
|
`assets/` folder.
|
||||||
|
|
||||||
Whatever object you have in hands that comes from the database, they will
|
Whatever object you have in hand that comes from the database, they will
|
||||||
at least provide a minimal useful set of API methods and properties.
|
at least provide a minimal useful set of API methods and properties.
|
||||||
|
|
||||||
Plugins can subclass source objects to come up with their own source
|
Plugins can subclass source objects to come up with their own source
|
||||||
|
@ -14,7 +14,7 @@ The `Pad` is a helper class that provides basic access to querying the
|
|||||||
database. Inside templates an instance of it is available under the
|
database. Inside templates an instance of it is available under the
|
||||||
`site` variable automatically.
|
`site` variable automatically.
|
||||||
|
|
||||||
To understand what the pad does you need to consider what it does. The
|
To understand what the pad does you need to consider what it is. The
|
||||||
pad is similar to a `connection` in a regular database. Whenever you
|
pad is similar to a `connection` in a regular database. Whenever you
|
||||||
load a record it's temporarily cached on the pad. So unless you overflow
|
load a record it's temporarily cached on the pad. So unless you overflow
|
||||||
the cache, loading the object a second time will most likely return an
|
the cache, loading the object a second time will most likely return an
|
||||||
|
@ -6,9 +6,12 @@ type: sysfield
|
|||||||
---
|
---
|
||||||
body:
|
body:
|
||||||
|
|
||||||
This indicates the type of the attachment. Currently only a small set of
|
This indicates the type of the attachment, which is detected by file extension.
|
||||||
attachments is detected. The most useful attachment type is `image` which
|
Currently only a small set of attachment types are detected, with the most
|
||||||
identifies images. The attachments are detected by the file extension.
|
useful one being `image`.
|
||||||
|
|
||||||
!!!! This feature in many ways does not entirely work as you would expect
|
!!!! This feature in many ways does not entirely work as you would expect
|
||||||
and should be taken is something that will improve in future versions.
|
and should be taken as something that will improve in future versions.
|
||||||
|
|
||||||
|
Read more about attachments
|
||||||
|
[in the content section :ref](../../../../content/attachments/contents.lr)
|
||||||
|
@ -12,8 +12,8 @@ This event is emitted right before a template is rendered and can be used
|
|||||||
to inject values directly into the template context. The context is always
|
to inject values directly into the template context. The context is always
|
||||||
provided and is a dictionary that can be modified.
|
provided and is a dictionary that can be modified.
|
||||||
|
|
||||||
What's important to know that this is not the only way to modify the template
|
It's important to know that this is not the only way to modify the template
|
||||||
context. Another one is to modify the underlying [Jinja Environment
|
context. Another method is to modify the underlying [Jinja Environment
|
||||||
:ref](../../../environment/jinja-env/) on the environment directly. The
|
:ref](../../../environment/jinja-env/) on the environment directly. The
|
||||||
difference is that the globals from the `jinja_env` are available in *all*
|
difference is that the globals from the `jinja_env` are available in *all*
|
||||||
templates whereas the modified template context is only available in the
|
templates whereas the modified template context is only available in the
|
||||||
|
@ -7,7 +7,7 @@ summary: The human readable plugin description.
|
|||||||
body:
|
body:
|
||||||
|
|
||||||
This is a short string with some more explanation of what the plugin does.
|
This is a short string with some more explanation of what the plugin does.
|
||||||
It's shown in the UI to give the user some ideas about it's operation.
|
It's shown in the UI to give the user some ideas about its operation.
|
||||||
|
|
||||||
## Example
|
## Example
|
||||||
|
|
||||||
|
@ -52,8 +52,13 @@ so they might not keep pace with development on Lektor.
|
|||||||
* [thumbnail-generator :ext](https://github.com/skorokithakis/lektor-thumbnail-generator): A plugin allowing you to generate configurable thumbnails for all your attachment images, so you can link them in your posts
|
* [thumbnail-generator :ext](https://github.com/skorokithakis/lektor-thumbnail-generator): A plugin allowing you to generate configurable thumbnails for all your attachment images, so you can link them in your posts
|
||||||
* [rst :ext](https://github.com/fschulze/lektor-rst): A [reStructuredText](http://docutils.sourceforge.net) plugin
|
* [rst :ext](https://github.com/fschulze/lektor-rst): A [reStructuredText](http://docutils.sourceforge.net) plugin
|
||||||
* [make :ext](https://github.com/BarnabyShearer/lektor-make): Run `make lektor` for custom build systems
|
* [make :ext](https://github.com/BarnabyShearer/lektor-make): Run `make lektor` for custom build systems
|
||||||
|
* [jinja-content :ext](https://github.com/terminal-labs/lektor-jinja-content) Enable Jinja with the [Template Context](https://www.getlektor.com/docs/templates/#template-context) in your content fields, e.g. combining Jinja and Markdown.
|
||||||
|
* [slugify :ext](https://github.com/terminal-labs/lektor-slugify) Add a Jinja filter to slugify unicode.
|
||||||
|
* [natural-language :ext](https://github.com/terminal-labs/lektor-natural-language) Add filters to do basic natural language processing with NLTK. Find keywords and sentence structure naturally.
|
||||||
|
* [strip-html-tags :ext](https://github.com/terminal-labs/lektor-strip-html-tags) Add a filter to transform HTML into simple text by stripping HTML tags.
|
||||||
* [npm-support :ext](https://github.com/sterin/lektor-npm-support): adds support for using npm/yarn to build assets in Lektor using tools such as [Parcel](https://parcel.js.org), [webpack](https://webpack.js.org), etc.
|
* [npm-support :ext](https://github.com/sterin/lektor-npm-support): adds support for using npm/yarn to build assets in Lektor using tools such as [Parcel](https://parcel.js.org), [webpack](https://webpack.js.org), etc.
|
||||||
|
|
||||||
|
|
||||||
! Have your own plugin and you want to see it here? Just [edit this page
|
! Have your own plugin and you want to see it here? Just [edit this page
|
||||||
on GitHub :ref](https://github.com/lektor/lektor-website/edit/master/content/docs/plugins/list/contents.lr),
|
on GitHub :ref](https://github.com/lektor/lektor-website/edit/master/content/docs/plugins/list/contents.lr),
|
||||||
add your plugin to the list and send a pull request.
|
add your plugin to the list and send a pull request.
|
||||||
|
BIN
content/showcase/andrew-shay/1-frontpage.png
Normal file
BIN
content/showcase/andrew-shay/1-frontpage.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 592 KiB |
BIN
content/showcase/andrew-shay/2-blog.png
Normal file
BIN
content/showcase/andrew-shay/2-blog.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 82 KiB |
11
content/showcase/andrew-shay/contents.lr
Normal file
11
content/showcase/andrew-shay/contents.lr
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
name: Andrew Shay
|
||||||
|
---
|
||||||
|
url: https://www.andrewshay.me
|
||||||
|
---
|
||||||
|
cover_image: 1-frontpage.png
|
||||||
|
---
|
||||||
|
description:
|
||||||
|
|
||||||
|
This is my personal website that I use to showcase my projects and discuss software engineering.
|
||||||
|
|
||||||
|
[View the Sourcecode on GitHub](https://github.com/Andrew-Shay/andrew_shay_me_website)
|
Loading…
Reference in New Issue
Block a user