Showing 161 of 251 total issues

Similar blocks of code found in 3 locations. Consider refactoring.
Open

            <a
              href={ `javascript:sharePost('http://www.facebook.com/sharer.php?p[title]=Gisto&p[summary]=${title}&p[url]=${url}','Sahare ${title} via Facebook',520,350);` }
              className="btn bg-grey fb txt-white"><i className="fa fa-facebook"/>
            </a>
Severity: Minor
Found in docs/src/templates/blog-post.js and 2 other locations - About 40 mins to fix
docs/src/templates/blog-post.js on lines 50..53
docs/src/templates/blog-post.js on lines 65..68

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 53.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Identical blocks of code found in 2 locations. Consider refactoring.
Open

      const downloads = latest.assets
        .map((asset) => {
          return dataStructure(asset);
        })
        .filter((os) => {
Severity: Minor
Found in docs/src/components/Downloads.js and 1 other location - About 40 mins to fix
docs/src/components/Downloads.js on lines 67..73

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 53.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    expect(dispatchSpy)
      .toHaveBeenCalledWith({
        action: {
          type: {
            FAILURE: 'GET_RATE_LIMIT_FAILURE',
Severity: Minor
Found in __tests__/middlewares/gitHubAPI.spec.js and 1 other location - About 40 mins to fix
__tests__/middlewares/gitHubAPI.spec.js on lines 101..112

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 53.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 3 locations. Consider refactoring.
Open

            <a
              href={ `mailto:?Subject=Gisto: ${title}&amp;Body=${title} at ${url}` }
              className="btn bg-grey txt-white"><i className="fa fa-envelope"/>
            </a>
Severity: Minor
Found in docs/src/templates/blog-post.js and 2 other locations - About 40 mins to fix
docs/src/templates/blog-post.js on lines 50..53
docs/src/templates/blog-post.js on lines 55..58

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 53.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const Languages = styled.span`
  color: ${(props) => props.theme.baseAppColor};
  border: 1px solid ${(props) => props.theme.baseAppColor};
  font-size: 11px;
  padding: 1px 3px;
Severity: Major
Found in src/components/layout/headers/SnippetHeader.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const Box = styled.div`
  background: ${(props) => props.theme.lightText};
  padding: 20px;
  border-radius: 3px;
  box-shadow: 0 0 10px ${(props) => props.theme.borderColor};
Severity: Major
Found in src/components/layout/content/DashBoard.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const H4 = styled.h4`
  color: ${(props) => props.theme.baseAppColor};
  border-bottom: 1px dashed ${(props) => props.theme.baseAppColor};
  padding-bottom: 20px;
`;
Severity: Major
Found in src/components/layout/content/settings/Editor.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const Box = styled.input`
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeSpeed;
  width: 15px;
  height: 15px;
Severity: Major
Found in src/components/common/controls/Checkbox.js and 10 other locations - About 35 mins to fix
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

export const HeaderSection = styled.div`
  background: ${(props) => props.theme.baseAppColor};
  flex: 1;
  border-right: 1px solid ${(props) => props.theme.baseAppColor};
  display: flex;
Severity: Major
Found in src/components/layout/headers/MainHeader.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const H4 = styled.h4`
  color: ${(props) => props.theme.baseAppColor};
  border-bottom: 1px dashed ${(props) => props.theme.baseAppColor};
  padding-bottom: 20px;
`;
Severity: Major
Found in src/components/layout/content/settings/Base.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const Table = styled.table`
  margin: 0;
  padding: 0;
  border-collapse: collapse;
  table-layout: fixed;
Severity: Major
Found in src/components/common/editor/Csv.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const H4 = styled.h4`
  color: ${(props) => props.theme.baseAppColor};
  border-bottom: 1px dashed ${(props) => props.theme.baseAppColor};
  padding-bottom: 20px;
`;
Severity: Major
Found in src/components/layout/content/settings/Snippets.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const UpdateInfo = styled.div`
  border: 1px solid ${(props) => props.theme.baseAppColor};
  padding: 10px;
  background: ${(props) => props.theme.bg};
  border-radius: 3px;
Severity: Major
Found in src/components/layout/content/About.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const Tag = styled.span`
  border: 1px solid ${(props) => props.theme.baseAppColor};
  color: ${(props) => props.theme.baseAppColor};
  padding: 1px 3px;
  border-radius: 3px;
Severity: Major
Found in src/components/layout/sidebar/Sidebar.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/MainHeader.js on lines 69..83
src/components/layout/headers/SnippetHeader.js on lines 74..83

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    const initial = initialState({
      filter: {
        text: 'html',
        tags: ['HTML', 'CSS', 'JS'],
        language: '',
Severity: Minor
Found in __tests__/reduceres/snippets.spec.js and 1 other location - About 35 mins to fix
__tests__/reduceres/snippets.spec.js on lines 94..103

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 11 locations. Consider refactoring.
Open

const RateLimit = styled.span`
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  color: ${(props) => props.theme.headerBgLightest};
Severity: Major
Found in src/components/layout/headers/MainHeader.js and 10 other locations - About 35 mins to fix
src/components/common/controls/Checkbox.js on lines 5..38
src/components/common/editor/Csv.js on lines 11..24
src/components/layout/content/About.js on lines 27..32
src/components/layout/content/DashBoard.js on lines 52..57
src/components/layout/content/settings/Base.js on lines 34..38
src/components/layout/content/settings/Editor.js on lines 46..50
src/components/layout/content/settings/Snippets.js on lines 47..51
src/components/layout/headers/MainHeader.js on lines 29..40
src/components/layout/headers/SnippetHeader.js on lines 74..83
src/components/layout/sidebar/Sidebar.js on lines 39..45

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    const initial = initialState({
      filter: {
        text: '',
        tags: ['HTML', 'CSS', 'JS'],
        language: '',
Severity: Minor
Found in __tests__/reduceres/snippets.spec.js and 1 other location - About 35 mins to fix
__tests__/reduceres/snippets.spec.js on lines 124..133

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 52.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    const expected = initialState({
      filter: {
        text: '',
        tags: ['HTML', 'CSS'],
        language: '',
Severity: Minor
Found in __tests__/reduceres/snippets.spec.js and 1 other location - About 35 mins to fix
__tests__/reduceres/snippets.spec.js on lines 105..114

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 51.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    if (isBoolean) {
      setBooleanSetting(key);
    } else {
      setSetting(key, value);
      if (key === 'settings-icons' || key === 'settings-notification-position') {
Severity: Minor
Found in src/components/layout/content/settings/Base.js and 1 other location - About 35 mins to fix
src/components/layout/content/settings/Snippets.js on lines 56..63

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 51.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Similar blocks of code found in 2 locations. Consider refactoring.
Open

    if (isBoolean) {
      setBooleanSetting(key);
    } else {
      setSetting(key, value);
      if (key === 'settings-snippet-order-direction' || key === 'settings-snippet-order-field') {
Severity: Minor
Found in src/components/layout/content/settings/Snippets.js and 1 other location - About 35 mins to fix
src/components/layout/content/settings/Base.js on lines 43..50

Duplicated Code

Duplicated code can lead to software that is hard to understand and difficult to change. The Don't Repeat Yourself (DRY) principle states:

Every piece of knowledge must have a single, unambiguous, authoritative representation within a system.

When you violate DRY, bugs and maintenance problems are sure to follow. Duplicated code has a tendency to both continue to replicate and also to diverge (leaving bugs as two similar implementations differ in subtle ways).

Tuning

This issue has a mass of 51.

We set useful threshold defaults for the languages we support but you may want to adjust these settings based on your project guidelines.

The threshold configuration represents the minimum mass a code block must have to be analyzed for duplication. The lower the threshold, the more fine-grained the comparison.

If the engine is too easily reporting duplication, try raising the threshold. If you suspect that the engine isn't catching enough duplication, try lowering the threshold. The best setting tends to differ from language to language.

See codeclimate-duplication's documentation for more information about tuning the mass threshold in your .codeclimate.yml.

Refactorings

Further Reading

Severity
Category
Status
Source
Language