skyderby/skyderby

View on GitHub
app/javascript/utils/designated_lane.js

Summary

Maintainability
C
1 day
Test Coverage

Function default has 195 lines of code (exceeds 25 allowed). Consider refactoring.
Open

export default function (google, map, width, length, direction, opts = {}) {
  const DLOverlay = class extends google.maps.OverlayView {
    constructor(map, width, length, direction, opts) {
      super()

Severity: Major
Found in app/javascript/utils/designated_lane.js - About 7 hrs to fix

Function set_bounds has 35 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    set_bounds(point) {
      const center_lat = point.lat()
      const center_lon = point.lng()

      const top_point = Geospatial.destiantion_by_bearing_and_distance(
Severity: Minor
Found in app/javascript/utils/designated_lane.js - About 1 hr to fix

Function create_rotate_marker has 28 lines of code (exceeds 25 allowed). Consider refactoring.
Open

    create_rotate_marker() {
      const icon = {
        path: 'M 0, 0 m -75, 0 a 75,75 0 1,0 150,0 a 75,75 0 1,0 -150,0',
        fillOpacity: 0.5,
        strokeWeight: 2,
Severity: Minor
Found in app/javascript/utils/designated_lane.js - About 1 hr to fix

Function default has 6 arguments (exceeds 4 allowed). Consider refactoring.
Open

export default function (google, map, width, length, direction, opts = {}) {
Severity: Minor
Found in app/javascript/utils/designated_lane.js - About 45 mins to fix

There are no issues that match your filters.

Category
Status