Skip to content
This repository has been archived by the owner on Jan 29, 2024. It is now read-only.

Cannot read properties of undefined (reading 'type') #355

Open
NinjaCross opened this issue Jan 16, 2022 · 11 comments
Open

Cannot read properties of undefined (reading 'type') #355

NinjaCross opened this issue Jan 16, 2022 · 11 comments

Comments

@NinjaCross
Copy link

NinjaCross commented Jan 16, 2022

Hi.
First of all, great project !
Unfortunately I'm not able to make it work,
Running hegel or npx hegel via CLI into the folder of my application, I have the error Cannot read properties of undefined (reading 'type')

This is my package.json

{
  "version": "1.0.0",
  "name": "my-website",
  "private": true,
  "engines": {
    "node": ">=17"
  },
  "scripts": {
    "eslint": "gulp --gulpfile gulpFile.js run-eslint"
  },
  "devDependencies": {
    "@babel/core": "^7.16.0",
    "@babel/eslint-parser": "^7.16.3",
    "@hegel/cli": "^0.0.45",
    "@babel/preset-flow": "^7.16.7",
    "eslint": "^8.4.1",
    "fs": "^0.0.2",
    "glob": "^7.2.0",
    "gulp": "^4.0.2",
    "gulp-clean": "^0.4.0",
    "gulp-cli": "^1.4.0",
    "gulp-eslint": "^6.0.0",
    "sass": "^1.44.0"
  }
}

This is my .hegelrc file

include:
  - ./wwwroot/js/**/*.js
exclude:
  - ./node_modules/**
types:
  - ./node_modules/@types

I'm using Babel only for ESLint, and I'm trying to use Hegel without involving Babel or other dependencies (it's not very clear to me if Babel is mandatory to use Hegel or not), but just to be sure, I created this .babelrc file

{
  "presets": [["@babel/preset-flow", { "all": true }]]
}

Can you please give me a suggestion ?
Thank you very much in advance.

@NinjaCross
Copy link
Author

@JSMonk can you please provide any suggestion about this error ?

@JSMonk
Copy link
Owner

JSMonk commented Feb 14, 2022

Hello @NinjaCross. Sorry for so long answer. Seems like it's an analysis error, so,I will fix it in a new version

@NinjaCross
Copy link
Author

Hello @NinjaCross. Sorry for so long answer. Seems like it's an analysis error, so,I will fix it in a new version

Thankyou @JSMonk , I'll eagerly wait for the new version then :)

@unrealsolver
Copy link
Contributor

@JSMonk , thank you! How can community help you? Can you maybe add some guide/architecture overview/roadmap for potential contributors? Currently some tests are failing, and there are some false-positives checking errors, which are hard to tell why it happens due to absence of comments.

@NinjaCross
Copy link
Author

@JSMonk do you have any update about this ?
We are eager to add Hegel to our tooling, but we cannot proceed until this is solved.
Thank you very much for you effort :)

@JSMonk
Copy link
Owner

JSMonk commented Mar 22, 2022

Hello @NinjaCross.
Sorry, but, unfortunately, I suspended the work on Hegel in a period of the war in Ukraine to focus on help to my parents and friends in Kharkiv/Kyiv.
I will continue work soon (in a few weeks).

@NinjaCross
Copy link
Author

@JSMonk I wish you and your family the best.
Thank you very much.

@trusktr
Copy link

trusktr commented Jun 16, 2022

That war has wreaked havoc. May your friends and fam be safe.

@mindplay-dk
Copy link

@JSMonk one year on, just passing by here, wondering if you and your family are okay? 🙏

@JSMonk
Copy link
Owner

JSMonk commented May 13, 2023

Thankfully, my family is safe, they are still in Ukraine (Kharkiv), but everything is alright.
Thank you a lot for your attention 🙏

@mindplay-dk
Copy link

Kharkiv, I hope they're not on the outskirts of the city.

If you need to run, come to Denmark. Currently, all Ukrainians receive a 1-year unconditional visa, free health care, work permit, access to education, temporary housing, and so on.

I hope you never have to run! But it sounds like this war might carry on for a while. 😔

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants