From 299f8a8c9e11bb67b43738dc3060ea2e87a30f9f Mon Sep 17 00:00:00 2001 From: Hunter Perrin Date: Mon, 20 Nov 2017 18:06:55 -0800 Subject: [PATCH] Updated readme. --- README.md | 49 +++++++++++++++++++++++++++++-------------------- 1 file changed, 29 insertions(+), 20 deletions(-) diff --git a/README.md b/README.md index e2feaf4..9ab25f9 100644 --- a/README.md +++ b/README.md @@ -22,27 +22,36 @@ This repository is the JavaScript query editor widget built with Svelte. For mor npm install --save nymph-query-editor ``` -To use, include the file from either the UMD, CommonJS, or IIFE lib folder, and instantiate with a target and list of Nymph entity classes: - -```js -var myQueryEditor = new HelloWorld({ - target: document.querySelector('query-editor'), - data: { - supportedClasses: [ - MyFirstEntity, - MySecondEntity - ], - options: { - "class": MyFirstEntity.class - }, - selectors: [ - { - "type": "&", - "gte": ["cdate", null, "-1 week"] +To use, include the files from the lib folder, and instantiate with a target and list of Nymph entity classes: + +```html + + + + ``` Then you can get the query by the options and selectors: