const cache = Object . create ( null ) ; function connect ( data , prefix ? ) { if ( prefix ) { Object . assign ( cache , Object . fromEntries ( Object . entries ( data ) . map ( ( [ key , value ] ) => [ key . startsWith ( prefix ) ? key . slice ( prefix . length ) : key , value , ] ) ) ) ; } else { Object . assign ( cache , data ) ; } } function extract ( request ) { return cache [ request ] ; } export { connect , extract , } ;