2017-04-21 40 views
2

カメラロールで写真を取得できますが、Selfies、Screeenshotsなどのスマートアルバムでフィルタリングすることは可能ですか?私はこれで試してみます:CameraRoll react-native smartAlbum

CameraRoll.getPhotos({ groupName: 'Favorites', groupTypes: 'Library', first: 36 }) 
.then((data) => { 
    const assets = data.edges; 
    const images = assets.map((asset) => { 
    console.log('Imagen', asset); 
    return asset.node.group_name; 
    }); 
    console.log('CameraRoll images', data, images); 
}) 
.catch(err => console.log('CameraRoll error', err)); 

しかし、常に空の配列を返します。

答えて

0

それが反応し、ネイティブので、使用をALAssetsLibraryことはできません、と私は写真のフレームワークを使用使用する必要があり、それが反応するネイティブ・写真・フレームワークを

https://github.com/olofd/react-native-photos-framework

を統合だそうソリューション