@ribajs/shopify
Advanced tools
Comparing version 0.17.1 to 0.18.0
{ | ||
"name": "@ribajs/shopify", | ||
"description": "Shopify extension for Riba.js", | ||
"version": "0.17.1", | ||
"version": "0.18.0", | ||
"author": "Pascal Garber <pascal@jumplink.eu>", | ||
"contributors": [], | ||
"url": "https://github.com/ribajs/riba", | ||
"url": "https://github.com/ribajs/riba/tree/master/packages/shopify", | ||
"main": "src/index.ts", | ||
@@ -49,4 +49,5 @@ "module": "src/index.ts", | ||
"dependencies": { | ||
"@ribajs/core": "^0.17.0" | ||
"@ribajs/core": "^0.17.0", | ||
"@ribajs/i18n": "^0.17.0" | ||
} | ||
} |
@@ -1,6 +0,13 @@ | ||
export * from './interfaces/interfaces'; | ||
import * as components from './components/shopify.components'; | ||
import * as formatters from './formatters/shopify.formatters'; | ||
import * as services from './services/shopify.services'; | ||
export const shopifyExtension = { | ||
import { IRibaModule } from '@ribajs/core'; | ||
export * from './components'; | ||
export * from './formatters'; | ||
export * from './services'; | ||
export * from './interfaces'; | ||
import * as components from './components'; | ||
import * as formatters from './formatters'; | ||
import * as services from './services'; | ||
export const shopifyModule = <IRibaModule> { | ||
formatters, | ||
@@ -11,34 +18,2 @@ services, | ||
// Add Shopify-specific formatters for Rivets.js. | ||
// export const money = (value, currency) => { | ||
// return Utils.formatMoney(value, ProductJS.settings.moneyFormat, 'money_format', currency); | ||
// }; | ||
// export const moneyWithCurrency = (value, currency) => { | ||
// return Utils.formatMoney(value, ProductJS.settings.moneyWithCurrencyFormat, 'money_with_currency_format', currency); | ||
// }; | ||
// export const weight = (grams) => { | ||
// switch (CartJS.settings.weightUnit) { | ||
// case 'kg': | ||
// return (grams / 1000).toFixed(CartJS.settings.weightPrecision); | ||
// case 'oz': | ||
// return (grams * 0.035274).toFixed(CartJS.settings.weightPrecision); | ||
// case 'lb': | ||
// return (grams * 0.00220462).toFixed(CartJS.settings.weightPrecision); | ||
// default: | ||
// return grams.toFixed(CartJS.settings.weightPrecision); | ||
// } | ||
// }; | ||
/** | ||
* Formats the product variant's weight. The weight unit is set in General Settings. | ||
* @see https://help.shopify.com/themes/liquid/filters/additional-filters#weightWithUnit | ||
*/ | ||
// export const weightWithUnit = (grams) => { | ||
// return export const weight(grams) + CartJS.settings.weightUnit; | ||
// }; | ||
// export const productImageSize = (src, size) => { | ||
// return CartJS.Utils.getSizedImageUrl(src, size); | ||
// }; | ||
export default shopifyModule; |
@@ -12,3 +12,3 @@ import { Debug, Utils, EventDispatcher } from '@ribajs/core'; | ||
IShopifyShippingRatesNormalized, | ||
} from '../interfaces/interfaces'; | ||
} from '../interfaces'; | ||
@@ -15,0 +15,0 @@ export interface IShopifyCartRequestOptions { |
@@ -6,3 +6,3 @@ import { Debug, Utils } from '@ribajs/core'; | ||
IShopifyProductVariant, | ||
} from '../interfaces/interfaces'; | ||
} from '../interfaces'; | ||
@@ -9,0 +9,0 @@ export interface IProductsCache { |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
108034
74
2841
2
+ Added@ribajs/i18n@^0.17.0
+ Added@ribajs/i18n@0.17.2(transitive)