From d14e9318b3bc13c316e914dcb2860cd01b89377a Mon Sep 17 00:00:00 2001 From: David East Date: Sat, 21 Feb 2015 12:43:15 -0800 Subject: [PATCH 1/3] Conditional logic for JS and Dart pages. --- public/docs/_data.json | 1 + public/docs/_quickstart.jade | 5 +++++ public/docs/dart/_data.json | 6 ++++++ public/docs/dart/quickstart.jade | 3 +++ public/docs/js/_data.json | 6 ++++++ public/docs/js/quickstart.jade | 3 +++ public/docs/quickstart.md | 1 - 7 files changed, 24 insertions(+), 1 deletion(-) create mode 100644 public/docs/_data.json create mode 100644 public/docs/_quickstart.jade create mode 100644 public/docs/dart/_data.json create mode 100644 public/docs/dart/quickstart.jade create mode 100644 public/docs/js/_data.json create mode 100644 public/docs/js/quickstart.jade delete mode 100644 public/docs/quickstart.md diff --git a/public/docs/_data.json b/public/docs/_data.json new file mode 100644 index 0000000000..0967ef424b --- /dev/null +++ b/public/docs/_data.json @@ -0,0 +1 @@ +{} diff --git a/public/docs/_quickstart.jade b/public/docs/_quickstart.jade new file mode 100644 index 0000000000..d409ac8fea --- /dev/null +++ b/public/docs/_quickstart.jade @@ -0,0 +1,5 @@ + +if lang == 'js' + h2 I like JavaScript +else if lang == 'dart' + h2 I like Dart diff --git a/public/docs/dart/_data.json b/public/docs/dart/_data.json new file mode 100644 index 0000000000..5e75138b7a --- /dev/null +++ b/public/docs/dart/_data.json @@ -0,0 +1,6 @@ +{ + "lang": "dart", + "quickstart": { + "lang": "dart" + } +} diff --git a/public/docs/dart/quickstart.jade b/public/docs/dart/quickstart.jade new file mode 100644 index 0000000000..d035102e8c --- /dev/null +++ b/public/docs/dart/quickstart.jade @@ -0,0 +1,3 @@ +h1 Dart Quickstart + +!= partial("../_quickstart") diff --git a/public/docs/js/_data.json b/public/docs/js/_data.json new file mode 100644 index 0000000000..f7f6d62889 --- /dev/null +++ b/public/docs/js/_data.json @@ -0,0 +1,6 @@ +{ + "lang": "js", + "quickstart": { + "lang": "js" + } +} diff --git a/public/docs/js/quickstart.jade b/public/docs/js/quickstart.jade new file mode 100644 index 0000000000..0a3e18739f --- /dev/null +++ b/public/docs/js/quickstart.jade @@ -0,0 +1,3 @@ +h1 JavaScript Quickstart + +!= partial("../_quickstart") diff --git a/public/docs/quickstart.md b/public/docs/quickstart.md deleted file mode 100644 index 8553f23306..0000000000 --- a/public/docs/quickstart.md +++ /dev/null @@ -1 +0,0 @@ -#Quickstart From 63e5bbe93eaf9bae21191377d6e5de288b2cfe74 Mon Sep 17 00:00:00 2001 From: David East Date: Sat, 21 Feb 2015 13:00:59 -0800 Subject: [PATCH 2/3] Unneeded fields in _data.json --- public/docs/dart/_data.json | 1 - public/docs/js/_data.json | 1 - 2 files changed, 2 deletions(-) diff --git a/public/docs/dart/_data.json b/public/docs/dart/_data.json index 5e75138b7a..b958728d06 100644 --- a/public/docs/dart/_data.json +++ b/public/docs/dart/_data.json @@ -1,5 +1,4 @@ { - "lang": "dart", "quickstart": { "lang": "dart" } diff --git a/public/docs/js/_data.json b/public/docs/js/_data.json index f7f6d62889..e787a7c641 100644 --- a/public/docs/js/_data.json +++ b/public/docs/js/_data.json @@ -1,5 +1,4 @@ { - "lang": "js", "quickstart": { "lang": "js" } From 11a501935074cf1ff85c6764300182b70df36590 Mon Sep 17 00:00:00 2001 From: David East Date: Sat, 21 Feb 2015 13:11:11 -0800 Subject: [PATCH 3/3] Template from _data.json --- public/docs/dart/_data.json | 4 +--- public/docs/dart/quickstart.jade | 2 +- public/docs/js/_data.json | 4 +--- public/docs/js/quickstart.jade | 2 +- 4 files changed, 4 insertions(+), 8 deletions(-) diff --git a/public/docs/dart/_data.json b/public/docs/dart/_data.json index b958728d06..6f078fc07c 100644 --- a/public/docs/dart/_data.json +++ b/public/docs/dart/_data.json @@ -1,5 +1,3 @@ { - "quickstart": { - "lang": "dart" - } + "lang": "dart" } diff --git a/public/docs/dart/quickstart.jade b/public/docs/dart/quickstart.jade index d035102e8c..743f5e71ef 100644 --- a/public/docs/dart/quickstart.jade +++ b/public/docs/dart/quickstart.jade @@ -1,3 +1,3 @@ h1 Dart Quickstart -!= partial("../_quickstart") +!= partial("../_quickstart", public.docs.dart._data) diff --git a/public/docs/js/_data.json b/public/docs/js/_data.json index e787a7c641..d84c9c6eb9 100644 --- a/public/docs/js/_data.json +++ b/public/docs/js/_data.json @@ -1,5 +1,3 @@ { - "quickstart": { - "lang": "js" - } + "lang": "js" } diff --git a/public/docs/js/quickstart.jade b/public/docs/js/quickstart.jade index 0a3e18739f..4095a11d3f 100644 --- a/public/docs/js/quickstart.jade +++ b/public/docs/js/quickstart.jade @@ -1,3 +1,3 @@ h1 JavaScript Quickstart -!= partial("../_quickstart") +!= partial("../_quickstart", public.docs.js._data)