Showing 90 of 251 total issues
Function snippets
has 212 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const snippets = (state = initialState, action) => {
switch (action.type) {
case AT.GET_SNIPPETS.SUCCESS: {
const lastUpdated = state.lastUpdated === null ? toISOString() : state.lastUpdated;
File SnippetHeader.js
has 516 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { drop, get, isEmpty, map, size, toString, isArray } from 'lodash/fp';
import styled from 'styled-components';
Function render
has 146 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const snippetUrl = getSnippetUrl('/gist');
const { snippets, match, editSnippet, comments } = this.props;
const snippet = get(match.params.id, snippets);
const snippetId = get('id', snippet);
Function render
has 140 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
return (
<section className="whiter boxes inner">
<div className="w-container">
<p className="txt-grey txt-center">
File NewSnippet.js
has 397 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import styled from 'styled-components';
import {
File DashBoard.js
has 385 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import styled, { css } from 'styled-components';
import { size, filter, map, flow, isEmpty, get } from 'lodash/fp';
File snippets.spec.js
has 368 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import * as AT from 'constants/actionTypes';
import { snippets as reducer } from 'reducers/snippets';
import { rawSnippets, snippet, snippets } from '../../__mocks__/snippets';
import { filter, head, keyBy, map, merge } from 'lodash/fp';
Function render
has 117 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const { theme, tags } = this.props;
const languageFromSettings = getSetting('setings-default-new-snippet-language', 'Text');
return (
Function render
has 112 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
if (isElectron) {
const { ipcRenderer } = require('electron');
ipcRenderer.on('token', (event, token) => {
Function render
has 106 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
render() {
const {
snippets,
privateSnippets,
starred,
File LogIn.js
has 340 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import PropTypes from 'prop-types';
import { connect } from 'react-redux';
import { get, isEmpty } from 'lodash/fp';
import styled from 'styled-components';
Function buildMenu
has 103 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
function buildMenu(mainWindow) {
const template = [];
const name = app.getName();
template.unshift(
File editor.ts
has 337 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
export const syntaxMap = {
ABAP: 'abap',
ActionScript: 'actionscript',
Ada: 'ada',
Agda: 'text',
Function componentDidMount
has 84 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
componentDidMount() {
if (isElectron) {
const { ipcRenderer } = require('electron');
const { app } = require('electron').remote;
const isMacOS = process.platform === 'darwin';
File gitHubAPI.js
has 296 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/* eslint consistent-return: 0 */
import * as superagent from 'superagent';
import * as AT from 'constants/actionTypes';
import { responseHandler } from 'middlewares/responseHandler';
Function HTML
has 77 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const HTML = (props) => {
return (
<html { ...props.htmlAttributes }>
<head>
<meta charSet="utf-8"/>
File Editor.js
has 288 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import React from 'react';
import { connect } from 'react-redux';
import PropTypes from 'prop-types';
import styled from 'styled-components';
File helpers.js
has 287 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
/* eslint no-console: 0 */
const { shell, app, Menu, ipcMain } = require('electron');
const { autoUpdater } = require('electron-updater');
const log = require('electron-log');
const { init } = require('@sentry/electron');
Function ui
has 69 lines of code (exceeds 25 allowed). Consider refactoring. Open
Open
export const ui = (state = initialState, action) => {
switch (action.type) {
case AT.GET_SNIPPETS.PENDING:
case AT.GET_SNIPPET.PENDING:
case AT.SET_STAR.PENDING:
File snippetsActions.spec.js
has 277 lines of code (exceeds 250 allowed). Consider refactoring. Open
Open
import * as AT from 'constants/actionTypes';
import * as snippetsActions from 'actions/snippets';
const files = {
'hi.txt': {