Superlinter

for any language

Superlinter

for any language

Replace all linters, Sonarqube and more with natural language
superlinter for any stack.

Replace all linters, Sonarqube and more with natural language
superlinter for any stack.

Trusted by engineers, from

Take a peek
Trag can review your code with very specific instructions.

Trag can lint patterns

Trag can lint patterns

Describe your pattern in plain english, it can be very specific, context aware, or it can be very high level, like

Describe your pattern in plain english, it can be very specific, context aware, or it can be very high level, like

High level patterns

High level patterns

Ensure we are not logging sensitive data.

Follow DRY principles.

Context aware patterns

Context aware patterns

Make sure to wrap any API calls, with module X to handle errors with Y error handling.

While working with the A make sure to do B and C.

Some pattern examples

Some pattern examples

A pattern in Trag defines a specific rule for code structure or behavior,
for example…

A pattern in Trag defines a specific rule for code structure or behavior,
for example…

Create

Pattern

Ensure that complex forms using NgRx only dispatch actions to update the store when form values actually change.

import { Component } from '@angular/core';
import { Store } from '@ngrx/store';
import { FormGroup, FormControl } from '@angular/forms';

@Component({
  selector: 'app-profile-form',
  templateUrl: './profile-form.component.html',
})
export class ProfileFormComponent {
  profileForm = new FormGroup({
    firstName: new FormControl(''),
    lastName: new FormControl(''),
  });

  constructor(private store: Store) {}

  onSubmit() {
   this.store.dispatch(updateProfile({ profile: this.profileForm.value }));
  }
}

Trag comment

The dispatch is done every time, regardless of whether the form values have changed, maybe revisit this part and make sure this is intended.

Pattern

Ensure that complex forms using NgRx only dispatch actions to update the store when form values actually change.

import { Component } from '@angular/core';
import { Store } from '@ngrx/store';
import { FormGroup, FormControl } from '@angular/forms';

@Component({
  selector: 'app-profile-form',
  templateUrl: './profile-form.component.html',
})
export class ProfileFormComponent {
  profileForm = new FormGroup({
    firstName: new FormControl(''),
    lastName: new FormControl(''),
  });

  constructor(private store: Store) {}

  onSubmit() {
   this.store.dispatch(updateProfile({ profile: this.profileForm.value }));
  }
}

Trag comment

The dispatch is done every time, regardless of whether the form values have changed, maybe revisit this part and make sure this is intended.

How to set up Trag

Install GitHub application and that's pretty much it.

Step 1

Install GitHub app

Step 2

Write custom patterns

Step 3

Open a Pull Request

How to set up Trag

Install GitHub application and that's pretty much it.

Step 1

Install GitHub app

Step 2

Write custom patterns

Step 3

Open a Pull Request

How to set up Trag

Install GitHub application and that's pretty much it.

Step 1

Install GitHub app

Step 2

Write custom patterns

Step 3

Open a Pull Request

Code reviews
made easy peasy.

Let Trag enforce your coding standards while you
focus on writing better code.

Code reviews
made easy
peasy.

Let Trag enforce your coding standards
while you focus on writing better code.

Code reviews
made easy peasy.

Let Trag enforce your coding standards while you
focus on writing better code.