Skip to content

Commit 3dd6dfe

Browse files
docs: project guidelines (#15)
1 parent eb111c2 commit 3dd6dfe

File tree

2 files changed

+13
-0
lines changed

2 files changed

+13
-0
lines changed

GUIDELINES.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
# Project Guidelines
2+
3+
## Core principles
4+
5+
1. We strive to create an API that is easy & intuitive to use, helps users avoid making mistakes, and exposes 95%+ power of regular expressions.
6+
2. We strive to balance replicating the [Swift Regex Builder API](https://developer.apple.com/documentation/regexbuilder) and creating an API native to TypeScript/JavaScript users.
7+
3. We should adjust our API where there are discrepancies between Swift and JavaScript regex behavior.
8+
9+
## Implementation guidelines
10+
11+
1. When the user passes the text to any regex component, it should be treated as an exact string to match and not as a regex string. We might provide an escape hatch for providing raw regex string through, but the user should use it explicitly.

README.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ const regex = buildRegex(oneOrMore('Hello '), 'World');
2121

2222
See the [contributing guide](CONTRIBUTING.md) to learn how to contribute to the repository and the development workflow.
2323

24+
See the [project guidelines](GUIDELINES.md) to understand our core principles.
25+
2426
## License
2527

2628
MIT

0 commit comments

Comments
 (0)