Skip to content

Latest commit

 

History

History
 
 

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

readme.md

Grammarly for Developers Code Examples

This directory contains numerous code examples you can use as you learn about the Grammarly Text Editor SDK. Most of the examples contain links to CodeSandbox—an open-source online code editor—so you can tinker with the code in your browser and better understand our features and functionality.

We've organized the examples in two ways: by Text Editor SDK feature and by the technology used.

Code examples by SDK feature

The following is a list of code examples organized by the SDK feature the app demonstrates.

Basic Configuration Apps

These apps show the basics of how to add the Grammarly Text Editor Plugin to text editors.

Starter Apps (Tutorials)

These are starter apps you can use as you work through the quick start guide. These starter apps do not yet have the Text Editor Plugin added to the text editors.

Note: The quick start guide is shown when you create a Grammarly for Developers app.

Activation

This app shows how you can set the Text Editor Plugin's activation property to focus or immediate.

Autocomplete

This app shows how you can turn on autocomplete for your app.

Autocomplete

Note: The Autocomplete feature is only available on the Plus plan.

Document dialect

This app shows how you can configure the document dialect for your app.

Document domain

This app shows how you can configure the document domain for your app.

Electron

These apps show how to add the Text Editor Plugin to Electron apps.

Events

These apps show how your app can respond to events (e.g., SessionStats, DocumentStats) in the Text Editor SDK.

Grammarly button menu position

This app shows how you can configure the menu position of the Grammarly button.

Introductory text

This app shows how you can configure the introductory text that is displayed for new users in suggestion cards.

Rich text editors

These apps show how you can add the Text Editor Plugin to various rich text editors.

Suggestion categories

This app shows how to configure suggestion categories for your app.

Note: The ability to configure suggestion categories is only available on the Plus plan.

Tone detector

This app shows how to turn on the tone detector for your app.

tone-detector

Note: The tone detector feature is only available on the Plus plan.

Trusted Authentication

These examples show how you can configure trusted authentication.

Turn off UI elements

These apps show three ways to turn off UI elements in the Text Editor Plugin.

Code examples by the technology used

The following is a list of code examples organized by the technology the app uses (e.g., programming language or framework).

Vanilla JavaScript

React

Vue

Angular

Electron

Java

Node