Skip to content

Commit

Permalink
add a table example
Browse files Browse the repository at this point in the history
  • Loading branch information
VVelox committed Sep 10, 2018
1 parent 8c99352 commit 8a80659
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions exampleSite/content/posts/fun-with-tables.org
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
author: "VVelox"
date: 2018-09-10
title: Fun With Tables
sort_tables: true
---

Below is a example of a sortable table in org mode.

#+BEGIN_SRC
| a | b | c | d | e |
|---+---+------------+--------------+---|
| 1 | f | 2017-03-14 | 127.0.0.1 | |
| 2 | b | 2018-02-14 | 192.168.15.2 | |
| 3 | e | 2017-03-15 | 192.168.1.1 | |
| 4 | d | 2012-03-14 | 10.10.10.10 | 3 |
#+END_SRC

Which results in table such as below.

| a | b | c | d | e |
|---+---+------------+--------------+---|
| 1 | f | 2017-03-14 | 127.0.0.1 | |
| 2 | b | 2018-02-14 | 192.168.15.2 | |
| 3 | e | 2017-03-15 | 192.168.1.1 | |
| 4 | d | 2012-03-14 | 10.10.10.10 | 3 |

By clicking on the table headers, you can change the sorting.

This is enabled on a page by putting the following in the Front Matter.

#+BEGIN_SRC
sort_tables: true
#+END_SRC

0 comments on commit 8a80659

Please sign in to comment.