I have a project that accesses profile images dynamically from JSON retrieved from an API service. The problem is I'm having a tough time figuring out where in the file system to put these images during development and what the path should be in the JSON.
Here is a small example:
<template>
<li :class="{'is-active': isActive}">
<div class="responsible">
<profile-picture :the-url="user.profilePicture" the-size="large"></profile-picture>
{{ user.name }}
</div>
</li>
</template>
<script>
import ProfilePicture from '../components/ProfilePicture'
export default {
data () {
return {
isActive: false
}
},
props: [
'user'
],
components: {
'profile-picture': ProfilePicture
}
}
</script>
So, what would be the path that user.profilePicture should have and where should that file be located in the filesystem? Again, I don't want to pack the image with webpack - I want this to come from a library of images that users have uploaded. Any help is appreciated!