Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ReferenceError: MapboxGeocoder is not defined #436

Open
sarahk opened this issue Apr 28, 2022 · 0 comments
Open

ReferenceError: MapboxGeocoder is not defined #436

sarahk opened this issue Apr 28, 2022 · 0 comments

Comments

@sarahk
Copy link

sarahk commented Apr 28, 2022

React/NextJS

In my component, I start by trying to import

import mbxGeocoding from '@mapbox/mapbox-sdk/services/geocoding';

and the linter tells me

Could not find a declaration file for module '@mapbox/mapbox-sdk/services/geocoding'.

Where am I going wrong?

package.json

"dependencies": {
    "@dnd-kit/core": "^5.0.3",
    "@dnd-kit/sortable": "^6.0.1",
    "@dnd-kit/utilities": "^3.1.0",
    "@mapbox/mapbox-sdk": "^0.12.1",
    "axios": "^0.26.1",
    "daisyui": "^2.13.4",
    "date-fns": "^2.28.0",
    "firebase": "^9.6.4",
    "mapbox-gl": "^2.8.2",
    "next": "^12.1.2",
    "nookies": "^2.5.2",
    "react": "17.0.2",
    "react-data-table-component": "^7.4.7",
    "react-datepicker": "^4.6.0",
    "react-dom": "^17.0.2",
    "react-firebase-hooks": "^5.0.3",
    "react-geolocated": "^3.2.0",
    "react-hook-form": "^7.28.1",
    "react-hot-toast": "^2.2.0",
    "react-markdown": "^8.0.0",
    "react-scripts": "^5.0.1",
    "react-select": "^5.2.2",
    "styled-components": "^5.3.5",
    "use-reducer-async": "^2.1.0"
  },
  "devDependencies": {
    "@svgr/webpack": "^6.2.1",
    "autoprefixer": "^10.4.2",
    "eslint": "8.12.0",
    "eslint-config-next": "^12.0.1",
    "eslint-plugin-react-hooks": "^4.4.0",
    "postcss": "^8.4.5",
    "tailwind-watch": "^0.0.6",
    "tailwindcss": "^3.0.15",
    "tailwindcss-debug-screens": "^2.2.1"
  }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant