Giter Club home page Giter Club logo

reaction-example-plugin's Introduction

Reaction Example Plugin

These files are for the fictional store Bee's Knees, a manufacturer of infant clothes specializing in garments made from organically grown cotton.

This package is demonstrate how you can customize Reaction Commerce to meet your needs and accompanies the tutorial "Customizing Reaction".

reaction-example-plugin's People

Contributors

akarshit avatar brent-hoover avatar impactmass avatar josx avatar kvnkwon avatar mikemurray avatar mikeumus avatar prinzdezibel avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

reaction-example-plugin's Issues

Remove Blaze templates

This example plugin is still using Blaze templates. I understand that Blaze is out. Updating this project would really help people get started.

Error No such template: productList.

I apply the theme to learn and to make some customizing on it, It's work right like this but when I need to know what this block start in line 7 does https://github.com/reactioncommerce/reaction-example-plugin/blob/master/client/templates/products/productsLanding.html

I add the template name to register file "productListGridBeesKnees" instead of "productsLanding", not work after login because of the "productList" template not found.

first, I need to know whey "productList" not found?
and what is this block dose?

thank you, and sorry to write an issue.

Flesh out `debug bar`

My original idea was to do something like the Django-Debug-Toolbar. Probably not something that complex but there's probably a lot we could add like Session variables, Router params, user info, etc. Especially when you start working with Reaction it would be great to be able to see these easily.

page not found error

If I include this plugin, then I get a page not found error. I was following the tutorial which also resulted in the same error.

Is there a way to debug it?

Update example plugin for Reaction 1.9

Tasks

  • Update the example plugin code for 1.9
  • The example plugin tutorial code for 1.9
  • Update the README on this repo to reflect that it's been updated for 1.8 and 1.9

Error: Cannot find module '/server/startup/i18n'

Preconditions:

Node: 8.11.3
NPM: 6.3.0
Meteor Node: 8.11.3
Meteor NPM: 5.10.0
Reaction CLI: 0.29.0
Docker: 18.06.1-ce
OS: Ubuntu 18.04

Steps to reproduce:

  1. Install fresh Reaction Commerce.
  2. Clone reaction-example-plugin in /imports/plugins/custom.
  3. Run reaction reset command on root.
  4. Run reaction command.

Expected result:
Everything works fine.

Actual result:

in the root directory of your application.
/home/shahrukh/.meteor/packages/meteor-tool/.1.7.0_3.u9lhms.hf7k++os.linux.x86_64+web.browser+web.browser.legacy+web.cordova/mt-os.linux.x86_64/dev_bundle/server-lib/node_modules/fibers/future.js:280
						throw(ex);
						^

Error: Cannot find module '/server/startup/i18n'
    at makeMissingError (packages/modules-runtime.js:231:12)
    at require (packages/modules-runtime.js:241:19)
    at index.js (imports/plugins/custom/reaction-example-plugin/server/i18n/index.js:1:35)
    at fileEvaluate (packages/modules-runtime.js:339:7)
    at require (packages/modules-runtime.js:238:16)
    at index.js (imports/plugins/custom/reaction-example-plugin/server/index.js:1:14)
    at fileEvaluate (packages/modules-runtime.js:339:7)
    at require (packages/modules-runtime.js:238:16)
    at plugins.js (server/plugins.js:1:2604)
    at fileEvaluate (packages/modules-runtime.js:339:7)
    at require (packages/modules-runtime.js:238:16)
    at /home/shahrukh/nodeApps/rc102/.meteor/local/build/programs/server/app/app.js:90711:1
    at /home/shahrukh/nodeApps/rc102/.meteor/local/build/programs/server/boot.js:411:36
    at Array.forEach (<anonymous>)
    at /home/shahrukh/nodeApps/rc102/.meteor/local/build/programs/server/boot.js:220:19
    at /home/shahrukh/nodeApps/rc102/.meteor/local/build/programs/server/boot.js:471:5
=> Exited with code: 1

Reaction init VS tutorial

Hello,
I'm trying to learn Reaction and I'm following the documentation.
However, it seems installing reaction how it is described in https://docs.reactioncommerce.com/reaction-docs/master/installation leads to a unstable version of Reaction. See the following issue as an example:
#17

Is it only a tutorial issue ?
Is there any option to get the last stable version using "reaction init" ?
Could you update the documentation so newbies can start working with Reaction again ?

I'm concern about Reaction plugins. An argument to use them is: "implement your plugins, no need to change the core, only pull the latest core version, your plugins will still work". However, it seems not the case.

Thanks for your help.

No such template: productGrid

After applying this plugin and restarting the reaction commerce server, I am getting the following error:

Error: No such template: productGrid
    at blaze.js?hash=f33d3df…:3212
    at Blaze.View.<anonymous> (spacebars.js?hash=ebf9381…:68)
    at blaze.js?hash=f33d3df…:1934
    at Function.Template._withTemplateInstanceFunc (blaze.js?hash=f33d3df…:3744)
    at blaze.js?hash=f33d3df…:1932
    at Object.Blaze._withCurrentView (blaze.js?hash=f33d3df…:2271)
    at viewAutorun (blaze.js?hash=f33d3df…:1931)
    at Tracker.Computation._compute (tracker.js?hash=997515f…:339)
    at new Tracker.Computation (tracker.js?hash=997515f…:229)
    at Object.Tracker.autorun (tracker.js?hash=997515f…:613)

Page reloads on route.

Hi,

I have added example plugin the in the custom directory. And added new route namely "/addRecipe"
with following code:

  1. In /client/templates/layouts/core.js file
    <a href={Reaction.Router.pathFor("addRecipe")}>Add Recipe</a>
  2. In registry of register.js file
    { route: "/addRecipe", name: "addRecipe", template: "addRecipe", workflow: "coreProductGridWorkflow" }

With the above code modifications, when I click on the "Add Recipe" link, page is reloaded.

How do I make it in such a way that it does not reload on routing, like we click on the "SHOP" from home page, the page never reloads.

Help understanding the template mapping with a Custom Nav

Hi there, I am using this as a foundation for creating a custom plugin to help understand the process by which the templates are pulled in. For example I want to include this component to override the default layout nav/brand logic

<template name="navigationBrandCustom">
  <a class="brand" href="{{pathFor '/'}}" title="{{siteName}}">
    {{#if logo}}
      <div class="logo">
        <img src="{{logo.url}}" alt="{{siteName}}">
      </div>
    {{else}}
      <span class="title">{{siteName}}</span>
    {{/if}}
  </a>
</template>

Is it possible to get a little info on how to wire this up into the plugin? I've tried a number of options and at the moment I am seeing a "This site requires JavaScript. Please enable it in your browser settings." message.

[Error] Blocked script execution in 'http://localhost:3000/' because the document's frame is sandboxed and the 'allow-scripts' permission is not set. (x142)

I would expect to change the layoutHeader value to my header template, but that doesn't seem to work in:

import { Reaction } from "/server/api";

// Register package as ReactionCommerce package
Reaction.registerPackage({
  label: "Hydrotik",
  name: "hydrotik",
  icon: "fa fa-vine",
  autoEnable: true,
  registry: [
    {
      route: "/about",
      name: "about",
      template: "aboutUs",
      workflow: "coreWorkflow"
    }
  ],
  layout: [{
    layout: "layoutCustom",
    workflow: "coreWorkflow",
    collection: "Products",
    theme: "default",
    enabled: true,
    structure: {
      template: "productsLanding",
      layoutHeader: "layoutHeader",
      layoutFooter: "layoutFooter",
      notFound: "productNotFound",
      dashboardHeader: "",
      dashboardControls: "dashboardControls",
      dashboardHeaderControls: "",
      adminControlsFooter: "adminControlsFooter"
    } }
  ]
});

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.