altadena-expo-map
v1.0.3
Published
System for Data Processing, Storing, and Visualization of fire-affected parcels for Altadena and Palisades Neighborhoods as a result of January 2025 fires in the Los Angeles area.
Maintainers
Readme
Altadena Map - Expo Compatible Library
A React/React Native library for Data Processing, Storing, and Visualization of fire-affected parcels for Altadena and Palisades Neighborhoods as a result of January 2025 fires in the Los Angeles area.
Installation
npm install altadena-expo-mapUsage
React Native / Expo
import { AltadenaMap } from 'altadena-expo-map';
export default function App() {
return (
<AltadenaMap
MAP_TOKEN="your_mapbox_token"
BASE_SOURCE={yourBaseSource}
MASTER_SOURCE={yourMasterSource}
user={userObject}
/>
);
}Web (React)
import { AltadenaMap } from 'altadena-expo-map';
function App() {
return (
<AltadenaMap
MAP_TOKEN="your_mapbox_token"
BASE_SOURCE={yourBaseSource}
MASTER_SOURCE={yourMasterSource}
user={userObject}
/>
);
}Props
MAP_TOKEN(string): Your Mapbox access tokenBASE_SOURCE(object): Base map data sourceMASTER_SOURCE(object): Master map data sourceuser(object, optional): User configuration object
Development
# Install dependencies
npm install
# Build the library
npm run build
# Development mode with watch
npm run dev
# Clean build artifacts
npm run cleanBuild Output
The library builds to dist/index.esm.js as an ES module, making it compatible with:
- React Native / Expo applications
- Modern React web applications
- Module bundlers that support ES modules
Dependencies
This library has the following peer dependencies:
expo>= 48.0.0react>= 18.0.0react-dom>= 18.0.0react-native>= 0.70.0
Migration from Vite
This project has been migrated from a Vite-based web application to an Expo-compatible library using Rollup. The migration includes:
- ✅ Replaced Vite with Rollup bundler
- ✅ Added TypeScript support
- ✅ Configured for library packaging
- ✅ Made compatible with React Native/Expo
- ✅ Maintained all existing functionality
License
MIT
