@khanacademy/perseus-linter 0.1.0 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "description": "Linter engine for Perseus",
4
4
  "author": "Khan Academy",
5
5
  "license": "MIT",
6
- "version": "0.1.0",
6
+ "version": "0.2.0",
7
7
  "publishConfig": {
8
8
  "access": "public"
9
9
  },
@@ -8,7 +8,7 @@ import * as PureMarkdown from "@khanacademy/pure-markdown";
8
8
  import Selector from "../selector.js";
9
9
  import TreeTransformer from "../tree-transformer.js";
10
10
 
11
- describe("Gorgon selector matching:", () => {
11
+ describe("PerseusLinter selector matching:", () => {
12
12
  const markdown = `
13
13
  ### A
14
14
 
@@ -4,7 +4,7 @@ import * as PureMarkdown from "@khanacademy/pure-markdown";
4
4
  import Rule from "../rule.js";
5
5
  import TreeTransformer from "../tree-transformer.js";
6
6
 
7
- describe("Gorgon lint Rules class", () => {
7
+ describe("PerseusLinter lint Rules class", () => {
8
8
  const markdown = `
9
9
  ## This Heading is in Title Case
10
10
 
@@ -1,7 +1,7 @@
1
1
  // @flow
2
2
  import Selector from "../selector.js";
3
3
 
4
- describe("gorgon selector parser", () => {
4
+ describe("PerseusLinter selector parser", () => {
5
5
  const validExpressions = [
6
6
  "*",
7
7
  " * ",
@@ -1,7 +1,7 @@
1
1
  // @flow
2
2
  import TreeTransformer from "../tree-transformer.js";
3
3
 
4
- describe("gorgon tree transformer", () => {
4
+ describe("PerseusLinter tree transformer", () => {
5
5
  function clone(o) {
6
6
  return JSON.parse(JSON.stringify(o));
7
7
  }
package/src/index.js CHANGED
@@ -13,7 +13,7 @@ const allLintRules: $ReadOnlyArray<$FlowFixMe> = AllRules.filter(
13
13
  export {Rule, allLintRules as rules};
14
14
 
15
15
  //
16
- // Run the Gorgon linter over the specified markdown parse tree,
16
+ // Run the Perseus linter over the specified markdown parse tree,
17
17
  // with the specified context object, and
18
18
  // return a (possibly empty) array of lint warning objects. If the
19
19
  // highlight argument is true, this function also modifies the parse
package/src/rule.js CHANGED
@@ -1,6 +1,6 @@
1
1
  // @flow
2
2
  /**
3
- * The Rule class represents a Gorgon lint rule. A Rule instance has a check()
3
+ * The Rule class represents a Perseus lint rule. A Rule instance has a check()
4
4
  * method that takes the same (node, state, content) arguments that a
5
5
  * TreeTransformer traversal callback function does. Call the check() method
6
6
  * during a tree traversal to determine whether the current node of the tree
@@ -9,7 +9,7 @@
9
9
  * an error message, and the start and end positions within the node's content
10
10
  * string of the lint.
11
11
  *
12
- * A Gorgon lint rule consists of a name, a severity, a selector, a pattern
12
+ * A Perseus lint rule consists of a name, a severity, a selector, a pattern
13
13
  * (RegExp) and two functions. The check() method uses the selector, pattern,
14
14
  * and functions as follows:
15
15
  *
@@ -178,7 +178,7 @@ export type LintTester = (
178
178
  export type AppliesTester = (context: LintRuleContextObject) => boolean;
179
179
 
180
180
  /**
181
- * A Rule object describes a Gorgon lint rule. See the comment at the top of
181
+ * A Rule object describes a Perseus lint rule. See the comment at the top of
182
182
  * this file for detailed description.
183
183
  */
184
184
  export default class Rule {