Is Eslint functioning in just one Sublime Text project?

I have encountered an issue where I duplicated the .eslintrc and package.json files for two projects, but only the first project is able to run linting properly. The second project does not show any errors.

  • I am using sublime-linter with the eslint module.
  • I have ensured that the syntax settings are the same in both projects.
  • I have run npm install to install dependencies.
  • I have attempted to restart Sublime Text.
  • Upon comparing the node_modules folders, I noticed a discrepancy - estravers-fb is installed in the working project.
    • Why is this dependency not installed in the other project?
    • Is there a different command to properly install dev-dependencies besides npm install?

Here is my package.json:

{
    "name": "Read-hapi",
    "version": "1.0.0",
    "description": "learning the hapi framework",
    "repository": "https://github.com/Pushplaybang/learning-hapi.git",
    "main": "server.js",
    "dependencies": {
        "blipp": "^2.3.0",
        "boom": "^3.1.2",
        "cheerio": "^0.20.0",
        "good": "^6.6.0",
        "good-console": "^5.3.1",
        "handlebars": "^4.0.5",
        "hapi": "^13.0.0",
        "inert": "^3.2.0",
        "joi": "^8.0.3",
        "reading-time": "^1.0.2",
        "request-promise": "^2.0.1",
        "text-stats": "0.0.3",
        "valid-url": "^1.0.9",
        "vision": "^4.0.1"
    },
    "devDependencies": {
        "babel-eslint": "^5.0.0",
        "eslint": "^2.3.0",
        "eslint-config-airbnb": "^6.1.0",
        "eslint-plugin-react": "^4.2.0"
    },
    "scripts": {
        "test": "echo \"Error: no test specified\" && exit 1"
    },
    "author": "Paul van Zyl",
    "license": "ISC"
}

And here is my .eslintrc:

{
    "parser": "babel-eslint",
    "extends": "airbnb",
    "env": {
        "browser": true,
        "node": true
    },
    "rules": {
        "no-unused-vars": 0,
        "no-undef": 0
    }
}

Any assistance on resolving this issue would be greatly appreciated.

Answer №1

To resolve the current incompatibility issue between ESLint 2.3.0 and babel-eslint, consider downgrading ESLint to version ~2.2.0 in your package.json file or switching to the default Espree parser. You can stay updated on the progress of this issue by following the updates on eslint/eslint#5476.

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

A Guide to Parsing JSON Data in JavaScript

I am facing an issue with the JSON received from an AJAX call. The problem lies in the unexpected '\t' after a bullet point, causing a JavaScript error in the JSON.Parse(data.d) function. Can you provide advice on how to address this situati ...

Managing data from two tables in Node.js with ejs

I have a question regarding my node.js project that I need help with. As a beginner in this field, I believe the answer may be simpler than anticipated. In my code file named index.js, I found the following snippet after referring to some online documenta ...

What is the reason for having the navigation bar stretch across the entire width of the mobile device?

NEW QUESTION: How Can I Fix the Navigation Bar Issue on Mobile Devices? I apologize for any language issues as I am using a translator. Hello, I have encountered an issue with a website form containing a price list. When viewed on a mobile device, all the ...

Using jQuery to send data with an AJAX post request when submitting a form with

This is the code I'm working with: <html> <body> <?php include('header.php'); ?> <div class="page_rank"> <form name="search" id="searchForm" method="post"> <span class="my_up_text">ENTER THE WEBSITE TO ...

Exploring the potential of TypeScript with native dynamic ES2020 modules, all without the need for Node.js, while also enhancing

I have a TypeScript application that utilizes es16 modules, with most being statically imported. I am now looking to incorporate a (validator) module that is only imported in debug mode. Everything seems to be functioning properly, but I am struggling to f ...

Algorithmically alter the view of the webvr camera

I am looking to dynamically change the position of a view within a webvr scene. My approach involves using the position.add method. Below is the code snippet that demonstrates how I programmatically move the camera: <a-entity position="33 0 -33" rota ...

Is it possible that React.createElement does not accept objects as valid react children?

I am working on a simple text component: import * as React from 'react' interface IProps { level: 't1' | 't2' | 't3', size: 's' | 'm' | 'l' | 'xl' | 'xxl', sub ...

switch out javaScript for selenium

I'm attempting to replace the JavaScript functionality of a web page using Selenium (in Java with Firefox Geckodriver, if that makes a difference). Consider this webpage: <HTML><HEAD></HEAD> <BODY> <DIV id="time">Ti ...

Ways to modify menu when button is clicked?

I am currently working on creating an authentication-based menu in a React app. Menu Data: const menuItems = { primaryMenus: [ { title: 'Messages' }, { title: 'Register' }, { subMenus: { title: ...

How to utilize jQuery to eliminate HTML onchange code

This block of code features an HTML onchange attribute as well as the use of jQuery's change event on an input text. I want only the jQuery change event to take precedence. I have attempted to use both unbind and off without success. Can someone prov ...

Vanilla JS causing event to fire repeatedly

My code is written in Vanilla JS and I've encountered an issue with dynamically generated content. Each click on the dynamic content returns a different value than expected: First click: 1 Second click: 3 Third click: 6 Fourth click: 10 But it sh ...

How to add vertical bars within ng-repeat in AngularJS

I attempted to retrieve values from an array variable using ng-repeat within unordered lists. Although the values are displaying correctly and everything is functioning properly, I added vertical bars after each value to represent sub-categories on my page ...

Implementing Material UI datetime-local feature with no minute selection

Is there a way to hide minutes in a TextField with type = datetime-local? <TextField label="From" type="datetime-local" InputLabelProps={{ shrink: true, }} /> This is how it appears on my end: screenshot ...

Tips for clearing all content within a React Material UI table

How can I create a reset button to clear a table filled with user input data, without having to write functions from scratch? For example, similar to using clearLayer() for clearing a leaflet map. Thank you for any suggestions! //example of dynamical ...

Error: Unable to access the 'classList' property of null in HTMLSpanElement.expand function

Encountering a minor issue with my javascript code. Following a tutorial for a seemingly simple task: link What I did: Adapted the HTML from the tutorial to fit my desired visual outcome while maintaining correct class and id attributes. Utilized identic ...

Positioning html images to overlap each other without losing the ability to click

Currently, I am facing a challenge with positioning two images over each other. The back image should be at the bottom, while the center image needs to be on top of it. Additionally, there is a requirement for placing a random link (in this case google.com ...

What is the process for identifying children records of a parent (Adonis Lucid Many-to-Many) that match a specific criteria?

I am currently searching for the presence of specific Permissions within a single parent Role in a many-to-many relationship. const roles = await Role .query() .preload('permissions') this.role = roles.find(role => role.id === someid) co ...

Is there a way to modify the package version with yarn, either upgrading or downgrading?

Is there a way to downgrade the version of a package using yarn's "dependencies" feature? ...

Is it possible to use AJAX to change the class name of a Font Awesome icon?

I am considering updating the icon after deleting a row. Should I initially include the font awesome icon once in the blade, then remove the class name and add it back with ajax? blade: <div id="status-{{ $country->id }}"> <div id ...

Tips for utilizing browser cache in AJAX requests to prevent loading the refreshed JSON file

It may seem like a strange question, but I'm experiencing an issue with an AJAX call to a JSON file. Both the request and response headers do not indicate to not use cache, and in the browser settings, the Disable cache option is not checked. What mor ...