A Pen by Lauren Ferreira on CodePen.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { Component } from 'react' | |
import { loadReviews } from '../../../redux/actions/actions' | |
import { connect } from 'react-redux' | |
const mapStateToProps = state => { | |
return { | |
reviews: state.reviews.reviews | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import axios from 'axios'; | |
const url = process.env.NODE_ENV === 'production' ? "/api/v1/" : "http://localhost:8080/api/v1/" | |
export function loadReviews(){ | |
return(dispatch) => { | |
axios.get(`${url}reviews`) | |
.then((res)=> { | |
let reviews = res.data | |
dispatch({type: 'LOAD_REVIEWS', reviews}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import { combineReducers } from 'redux' | |
import reviews from './reducers/reviews' | |
import common from './reducers/common' | |
import { routerReducer } from 'react-router-redux' | |
export default combineReducers({ | |
reviews, | |
common, | |
router: routerReducer | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package mygame; | |
import com.jme3.app.SimpleApplication; | |
import com.jme3.light.DirectionalLight; | |
import com.jme3.material.Material; | |
import com.jme3.math.ColorRGBA; | |
import com.jme3.math.FastMath; | |
import com.jme3.math.Vector3f; | |
import com.jme3.renderer.RenderManager; | |
import com.jme3.scene.Spatial; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cv2 | |
img = cv2.imread("data/lena.jpg") | |
cv2.imshow('Img',img) | |
print('Shape: ', img.shape) | |
print('Size: ' , img.size) | |
print('Type: ' , img.dtype) |
OlderNewer