| 
									
										
										
										
											2015-01-23 02:52:41 -07:00
										 |  |  | This is what an entity looks like: | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | ```yml | 
					
						
							|  |  |  | # inherited from File Entity
 | 
					
						
							| 
									
										
										
										
											2020-11-08 20:01:26 -07:00
										 |  |  | path: My Posts/My-Old-Name.html | 
					
						
							|  |  |  | lastModifiedDate: 2015-07-04T13:56:01Z | 
					
						
							|  |  |  | createdDate: 2015-07-04T13:56:01Z | 
					
						
							|  |  |  | contents: "..." # whatever the file is | 
					
						
							| 
									
										
										
										
											2015-01-23 02:52:41 -07:00
										 |  |  | 
 | 
					
						
							|  |  |  | # inherited from Collection Entity
 | 
					
						
							| 
									
										
										
										
											2020-11-08 20:01:26 -07:00
										 |  |  | name: My-Old-Name.html | 
					
						
							|  |  |  | relativePath: My Posts | 
					
						
							|  |  |  | ext: .html | 
					
						
							|  |  |  | collection: posts | 
					
						
							| 
									
										
										
										
											2015-01-23 02:52:41 -07:00
										 |  |  | 
 | 
					
						
							|  |  |  | # inherited from Content Entity
 | 
					
						
							| 
									
										
										
										
											2020-11-08 20:01:26 -07:00
										 |  |  | frontmatter: '---\n...\n---' # frontmatter as a string | 
					
						
							|  |  |  | yml: {} # frontmatter, parsed | 
					
						
							|  |  |  | body: "I think ..." # body, after frontmatter | 
					
						
							| 
									
										
										
										
											2015-01-23 02:52:41 -07:00
										 |  |  | 
 | 
					
						
							|  |  |  | # inherited from Normalized Entity
 | 
					
						
							| 
									
										
										
										
											2020-11-08 20:01:26 -07:00
										 |  |  | title: My Title # yml.title | titlize(entity.name) | 
					
						
							|  |  |  | slug: my-title # slugify(title) | 
					
						
							|  |  |  | slug_path: my-posts # slugifyPath(relativePath) | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | year: 2014 | 
					
						
							|  |  |  | month: 07 | 
					
						
							|  |  |  | day: 04 | 
					
						
							|  |  |  | hour: 13 | 
					
						
							|  |  |  | twelve_hour: 1 | 
					
						
							|  |  |  | meridian: pm | 
					
						
							|  |  |  | minute: 22 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | categories: ["tech"] | 
					
						
							|  |  |  | tags: | 
					
						
							|  |  |  |   ["http", "url", "website"] | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   # includes index.html | 
					
						
							|  |  |  | relative_file: | 
					
						
							|  |  |  |   /posts/foo/index.html | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   # excludes index.html | 
					
						
							|  |  |  | relative_href: | 
					
						
							|  |  |  |   /posts/foo/ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   # actual url of this file, even if redirect | 
					
						
							|  |  |  |   # excludes index.html | 
					
						
							|  |  |  | url: | 
					
						
							|  |  |  |   http://dev.example.com/posts/foo/ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   # the appropriate url, even in a redirect or duplicate | 
					
						
							|  |  |  |   # excludes index.html | 
					
						
							|  |  |  | canonical_url: | 
					
						
							|  |  |  |   http://dev.example.com/posts/foo/ | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   # production url, even in development (for disqus, etc) | 
					
						
							|  |  |  |   # excludes index.html | 
					
						
							|  |  |  | production_url: http://example.com/posts/foo/ | 
					
						
							| 
									
										
										
										
											2015-01-23 02:52:41 -07:00
										 |  |  | ``` | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | Note: The option `env.explicitIndexes` turns on `/index.html`. This option is automatically turned on when Dropbox is the host. | 
					
						
							| 
									
										
										
										
											2015-01-23 15:01:02 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-11-08 20:01:26 -07:00
										 |  |  | ## TODO
 | 
					
						
							| 
									
										
										
										
											2015-01-23 15:01:02 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-11-08 20:01:26 -07:00
										 |  |  | - path relative from / in the browser | 
					
						
							|  |  |  | - path relative from base_path on the file system |