]> Devi Nivas Git - chevron.git/commitdiff
Add missing single quotes to dict keys in README examples
authorAkos Kiss <akiss@inf.u-szeged.hu>
Mon, 1 Oct 2018 16:37:56 +0000 (18:37 +0200)
committerAkos Kiss <akiss@inf.u-szeged.hu>
Wed, 3 Oct 2018 10:06:16 +0000 (12:06 +0200)
README.md

index 9cd855561b2027c84a627cd99376778b562d0c3d..63c76aceff825a1ab52e36830382acf64b5ef619 100644 (file)
--- a/README.md
+++ b/README.md
@@ -77,9 +77,9 @@ Python usage with unpacking
 import chevron
 
 args = {
-  template: 'Hello, {{ mustache }}!',
+  'template': 'Hello, {{ mustache }}!',
 
-  data: {
+  'data': {
     'mustache': 'World'
   }
 }
@@ -92,9 +92,9 @@ chevron supports partials (via dictionaries)
 import chevron
 
 args = {
-    template: 'Hello, {{> thing }}!',
+    'template': 'Hello, {{> thing }}!',
 
-    partials_dict: {
+    'partials_dict': {
         'thing': 'World'
     }
 }
@@ -107,13 +107,13 @@ chevron supports partials (via the filesystem)
 import chevron
 
 args = {
-    template: 'Hello, {{> thing }}!',
+    'template': 'Hello, {{> thing }}!',
 
     # defaults to .
-    partials_path: 'partials/',
+    'partials_path': 'partials/',
 
     # defaults to mustache
-    partials_ext: 'ms',
+    'partials_ext': 'ms',
 }
 
 # ./partials/thing.ms will be read and rendered
@@ -134,9 +134,9 @@ def inject_x(text, render):
     return render(text, {'x': 'data'})
 
 args = {
-    template: 'Hello, {{# first}} {{x}} || {{y}} || {{z}} {{/ first}}!  {{# inject_x}} {{x}} {{/ inject_x}}',
+    'template': 'Hello, {{# first}} {{x}} || {{y}} || {{z}} {{/ first}}!  {{# inject_x}} {{x}} {{/ inject_x}}',
 
-    data: {
+    'data': {
         'y': 'foo',
         'z': 'bar',
         'first': first,