Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- state = {
- cat: 'meow',
- dog: 'bark',
- fish: 'what sound do i make?',
- snake: 'im not wanted for this experiment',
- turtle: 'im also not wanted for this experiment'
- }
- const {cat, dog, fish } = this.state;
- const animals = { cat, dog, fish };
- this.pets(animals)
- const animals = {cat, dog, fish} = this.state
- const {cat, dog, fish} = this.state
- this.pets(cat, dog, fish}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement