From 29ba593039352e864baf3f67ff61b18813fcebea Mon Sep 17 00:00:00 2001 From: Ethan Neff Date: Thu, 16 Feb 2017 17:13:47 -0800 Subject: [PATCH] docs: update examples in testbed and readme --- README.md | 19 +++++++++++-------- testbed/www/js/index.js | 17 ++++++++++------- 2 files changed, 21 insertions(+), 15 deletions(-) diff --git a/README.md b/README.md index 2dd8681c..c41d9732 100644 --- a/README.md +++ b/README.md @@ -341,10 +341,11 @@ $ipad_url: 'http://www.example.com/ipad', $deeplink_path: 'content/123', $match_duration: 2000, - more_custom: 'data', - even_more_custom: true, - this_is_custom: 41231, - this_is_date: Date.now() + custom_string: 'data', + custom_integer: Date.now(), + custom_boolean: true, + custom_array: [1, 2, 3, 4, 5], + custom_object: { 'random': 'dictionary' } } branchUniversalObj.generateShortUrl(analytics, properties).then(function (res) { @@ -375,9 +376,11 @@ // optional fields var properties = { $desktop_url: 'http://www.example.com/desktop', - more_custom: 'data', - even_more_custom: true, - this_is_custom: 41231 + custom_string: 'data', + custom_integer: Date.now(), + custom_boolean: true, + custom_array: [1, 2, 3, 4, 5], + custom_object: { 'random': 'dictionary' } } var message = 'Check out this link' @@ -734,7 +737,7 @@ | stage | | Use this to categorize the progress or category of a user when the link was generated. For example, if you had an invite system accessible on level 1, level 3 and 5, you could differentiate links generated at each level with this parameter | tags | | This is a free form entry with unlimited values `["string"]`. Use it to organize your link data with labels that don’t fit within the bounds of the above | alias | | Specify a link alias in place of the standard encoded short URL e.g. `yourdomain.com/youralias`. Link aliases are unique, immutable objects that cannot be deleted. You cannot change the alias of existing links. Aliases on the legacy `bnc.lt` domain are incompatible with Universal Links and Spotlight - | type | `0` | Set to `1` to limit deep linking behavior of the generated link to a single use. Set type to `2` to make the link show up under [Marketing Dashboard](https://dashboard.branch.io/marketing) while adding `$marketing_title` to `data`. + | type | `0` | Set to `1` to limit deep linking behavior of the generated link to a single use. Set type to `2` to make the link show up under [Marketing Dashboard](https://dashboard.branch.io/marketing) while adding `$marketing_title` to `data`. Must be an `int` - Properties diff --git a/testbed/www/js/index.js b/testbed/www/js/index.js index 0e4b6578..e6853168 100644 --- a/testbed/www/js/index.js +++ b/testbed/www/js/index.js @@ -185,10 +185,11 @@ function BranchDeepLink () { $ipad_url: 'http://www.example.com/ipad', $deeplink_path: 'content/123', $match_duration: 2000, - more_custom: 'data', - even_more_custom: true, - this_is_custom: 41231, - this_is_date: Date.now() + custom_string: 'data', + custom_integer: Date.now(), + custom_boolean: true, + custom_array: [1, 2, 3, 4, 5], + custom_object: { 'random': 'dictionary' } } // needs a universal object @@ -222,9 +223,11 @@ function BranchShareSheet () { // optional fields var properties = { $desktop_url: 'http://www.example.com/desktop', - more_custom: 'data', - even_more_custom: true, - this_is_custom: 41231 + custom_string: 'data', + custom_integer: Date.now(), + custom_boolean: true, + custom_array: [1, 2, 3, 4, 5], + custom_object: { 'random': 'dictionary' } } var message = 'Check out this link'