npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

com.fluid.simple-spellcheck

v1.1.1

Published

A simple spell check utility for use in the Unity Editor

Downloads

384

Readme

Unity Simple Spell Check

Unity simple spell check provides a fast and easy way to evaluate text in your game for basic spelling errors. It uses a local dictionary and allows for advanced configuration.

Features

Usage with text area attributes

Simple Usage

This will create a simple spell check button that evaluates a custom text area. If you need some basic spell checking for items or large blocks of text this should help.

public class ExampleDialogue : ScriptableObject {
    [TextAreaSpellCheck]
    public string text;
}

Usage with advanced project logging

Advanced Usage

You can log text from anywhere in your game with this pattern. You'll need to do this if you have large amounts of dialogue and you want to evaluate it all at once.

public class SpellCheckAllDialogue {
    [MenuItem("Spell Check/All Dialogue")]
    public static void CheckAllDialogue () {
        var logList = new List<LogEntry>();

        var guids = AssetDatabase.FindAssets($"t:{typeof(ExampleDialogue).Name}");
        foreach (var guid in guids) {
            var path = AssetDatabase.GUIDToAssetPath(guid);
            var asset = AssetDatabase.LoadAssetAtPath<ExampleDialogue>(path);

            if (!SpellCheck.Instance.IsInvalid(asset.Title) && !SpellCheck.Instance.IsInvalid(asset.Text)) continue;

            var log = new LogEntry($"{asset.Title} {asset.Text}", () => {
                SpellCheck.Instance.ClearValidation();
                SpellCheck.Instance.AddValidation("Title", asset.Title);
                SpellCheck.Instance.AddValidation("Text", asset.Text);
                Selection.activeObject = asset;
            });

            logList.Add(log);
        }

        SpellCheck.Instance.ShowLogs("All Example Dialogue Errors", logList);
    }
}

Installation

Unity Simple Spellcheck is used through Unity's Package Manager. In order to use it you'll need to add the following lines to your Packages/manifest.json file. After that you'll be able to visually control what specific version of Unity Simple Spellcheck you're using from the package manager window in Unity. This has to be done so your Unity editor can connect to NPM's package registry.

{
  "scopedRegistries": [
    {
      "name": "NPM",
      "url": "https://registry.npmjs.org",
      "scopes": [
        "com.fluid"
      ]
    }
  ],
  "dependencies": {
    "com.fluid.simple-spellcheck": "1.0.0"
  }
}

Releases

Archives of specific versions and release notes are available on the releases page.

Nightly Builds

To access nightly builds of the develop branch that are package manager friendly, you'll need to manually edit your Packages/manifest.json as so.

{
    "dependencies": {
      "com.fluid.simple-spellcheck": "https://github.com/ashblue/unity-simple-spellcheck.git#nightly"
    }
}

Note that to get a newer nightly build you must delete this line and any related lock data in the manifest, let Unity rebuild, then add it back. As Unity locks the commit hash for Git urls as packages.

Development Environment

If you wish to run to run the development environment you'll need to install the latest node.js. Then run the following from the root once.

npm install

If you wish to create a build run npm run build from the root and it will populate the dist folder.

Making Commits

All commits should be made using Commitizen (which is automatically installed when running npm install). Commits are automatically compiled to version numbers on release so this is very important. PRs that don't have Commitizen based commits will be rejected.

To make a commit type the following into a terminal from the root

npm run commit

This project was generated with Oyster Package Generator.