A Next.js application that displays current crime reports in Sweden using the Brottsplatskartan API.
- View recent crime reports nationally
- Search for crime reports by location
- Favorite crime reports (work in progress)
- Responsive design with Bootstrap
- Next.js 15 - React framework
- React 19 - UI library
- SWR - Data fetching and caching
- Bootstrap 5 - CSS framework
- Sass - CSS preprocessor
- FontAwesome - Icons
- Node.js 18. x or higher
- npm or yarn
- Clone the repository:
git clone https://github.com/mhed89/crime-locator.git
cd crime-locator- Install dependencies:
npm install
# or
yarn install- Run the development server:
npm run dev
# or
yarn dev- Open http://localhost:3000 in your browser
npm run build
npm start
# or
yarn build
yarn startRecently Updated (December 2025)
- Modernized all dependencies to latest versions
- Migrated to Next.js 14 and React 18
- Fixed deprecated Next.js patterns
- Improved error handling and loading states
- Enhanced code quality and consistency
- National crime report listing
- Location-based crime search
- Responsive design
- Crime report cards with images
- Map visualization
- Favorites functionality
- Improved filtering options
This project uses the public Brottsplatskartan API to fetch crime data from Sweden.
This is a personal hobby project, but suggestions and contributions are welcome!
This project is open source and available under the MIT License.
Made with ❤️ and a bit of ADHD hyperfocus