How to use the cloudinary-core.Util.camelCase function in cloudinary-core

To help you get started, we’ve selected a few cloudinary-core examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github cloudinary / cloudinary-react / src / Util / extractCloudinaryProps.js View on Github external
Object.keys(props).forEach(key => {
    const camelKey = Util.camelCase(key);
    const value = props[key];

    //if valid and defined add to cloudinaryProps
    if (CLOUDINARY_PROPS[camelKey]) {
      if (isDefined(props, key)) {
        result.cloudinaryProps[camelKey] = value;
      }
    } else if (CLOUDINARY_REACT_PROPS[camelKey]) { //cloudinary-react spesific prop
      result.cloudinaryReactProps[camelKey] = value;
    } else { //not valid so add to nonCloudinaryProps
      result.nonCloudinaryProps[key] = value;
    }
  });