- Extracted libp2p component from main app - Created modular package structure with interfaces and implementations - Added dependency injection for NativeModules - Configured for IOR loading from Gitea - Added comprehensive README and documentation
42 lines
1011 B
TypeScript
42 lines
1011 B
TypeScript
/**
|
|
* @metatrom/libp2p-native-bridge
|
|
*
|
|
* Native libp2p bridge for React Native applications
|
|
* Provides a unified interface for iOS and Android libp2p implementations
|
|
*/
|
|
|
|
// Main component export
|
|
export { Libp2pComponent, SimplePeerId, SimpleMultiaddr } from './implementations/Libp2pComponent';
|
|
|
|
// Settings exports
|
|
export {
|
|
SettingsService,
|
|
getSettingsService,
|
|
DEFAULT_SETTINGS,
|
|
type AppSettings,
|
|
type INativeModules
|
|
} from './implementations/SettingsService';
|
|
|
|
// UI Components
|
|
export { SettingsUI } from './implementations/SettingsUI';
|
|
|
|
// Interface exports
|
|
export * from './interfaces/ILibp2pComponent';
|
|
export * from './interfaces/types';
|
|
|
|
// Utility exports
|
|
export * from './utils/constants';
|
|
export * from './utils/eventHelpers';
|
|
export * from './utils/types';
|
|
|
|
// Re-export commonly used types for convenience
|
|
export type {
|
|
Connection,
|
|
ILibp2pComponent,
|
|
Libp2pEvents,
|
|
Libp2pOptions,
|
|
Multiaddr,
|
|
PeerId,
|
|
PeerInfo,
|
|
ProtocolHandler,
|
|
} from './interfaces/ILibp2pComponent'; |