awatson1978:dataset-dictionary

v1.0.3Published 9 years ago

This package has not had recent updates. Please investigate it's current state before committing to using it in your project.

dataset-dictionary is a Meteorite package that provides a the Webster Unabridged English Dictionary.


Installation

First, install the dataset-dictionary package from the command line, like so:

meteor add awatson1978:dataset-dictionary

Data/Document Model for Reading Data from Collection

Once done, you'll want to display data from the collection by adding the following templates into your document model. The class names come from Bootstrap v3.

1<template name="dictionaryIndexTemplate">
2  <div class="padded">
3    <div class="panel panel-info">
4      <div class="panel-heading">
5          <input id="dictionarySearchInput" type="text" placeholder="Filter..." value="life"></input>
6      </div>
7      <ul class="list-group">
8        {{#each dictionaryList}}
9          {{> dictionaryItemTemplate }}
10        {{/each}}
11      </ul>
12    </div>
13  </div>
14</template>
15<template name="dictionaryItemTemplate">
16  <li class="list-group-item"><span class="bold">{{ Word }}</span>  {{Definition}}</li>
17</template>
18
19

Controller for Reading Data from Collection

To dislay data, you'll also need to add the controllers, like so:

1
2Template.dictionaryIndexTemplate.helpers({
3  dictionaryList = function(){
4    return Dictionary.find({
5      'Word': { $regex: Session.get('dictionary_search'), $options: 'i' }
6    },{limit: 20});
7  }
8});
9

================================

Licensing

All code is MIT License. Use as you wish, including for commercial purposes.

================================

English Language Dictionary

This repository houses the contents of Webster's Unabridged English Dictionary.

The dictionary can be found in plain text form here

You'll also find some julia files that were used to parse the text and organize it into the nice json you see here.

Contents

  • dictionary.json: This is the raw data scraped from the dictionary. Unsurprisingly, it's in the format

of a dictionary, i.e. { "Word": "Definition" }

  • graph.json: This is a graph representation of the dictionary. Each word is paired with a list of the words that define it dictionary.txt: This is the plain text file (I converted it from ISO-8859-1 to UTF-8)

License

Creative Commons Attribution-NonCommerical 3.0 Unported

Creative Commons Attribution-NonCommercial 3.0 Unported Licencse