Skip to content

Commit

Permalink
add-info-on-extensions-and-angularjs-to-contribution-guidelines (#3119)
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaskikutis authored Sep 24, 2019
1 parent 4f2595f commit 44ae066
Showing 1 changed file with 23 additions and 1 deletion.
24 changes: 23 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,31 @@
## Contribution guidelines

### Pull requests
## Pull requests

* When opening a pull request, add a JIRA issue ID to the description.

## Technology

<details>
<summary>Do not use Angularjs for new features</summary>
Here are some issues with Angularjs which make it a much worse choice for future development compared to a TypeScript + React combination:
* Lack of TypeScript support - templates can't be typed at all, which is a large part of the code.
* Bad performance / hard to optimize, especially compared with React where most of the time implementing `shouldComponentUpdate` is enough.
* Templating system is poor, there isn't even an `if-else` statement(only `if`). The existence of the templating system itself is a disadvantage compared to React where you can use the full power of JavaScript for data transformations, caching and all other things you'd do in a "non-template" code.
</details>

<details>
<summary>Avoid writing Angularjs code when enhancing existing features</summary>
Use `reactToAngular1` which enables using React components inside Angularjs templates.
</details>

## Architecture

<details>
<summary>Build new features on top of extensions/features API</summary>
The API allows building new features without having to depend on the messier parts of the old code which can't be refactored at once. On top of that, the core will get smaller and easier to maintain as more features are moved on top of the API. See https://github.com/superdesk/superdesk-core/issues/1585.
</details>

## Testing

<details>
Expand Down

0 comments on commit 44ae066

Please sign in to comment.