Checkout Mantra: An Application Architecture for Meteor

There is no thing in Matra called “Pure UI components”, inside a component they can use any React component. (even containers build inside Mantra or stuff like meterial-ui)

What Mantra does is provide a way to create our app UI in a sensible way, while re-using as possible as we can.

If anyone following this thread, I have already released Mantra.
Here it is: Mantra - Application Architecture for Meteor

6 Likes

Will there be a opinion about schema/astronomy usage or is this out of scope?

That’s out of the scope.
Basically that’s for collections. They goes on what we call as application context.

Think of it this way. I have a tweet component that shows a list of tweets. If I want to reuse that component, I need to make a few containers to handle getting the right data context for say your tweet timeline, your mention timeline, and a search timeline. In the end, we are still displaying a tweet component and your reusability goes up. I think React naturally encourages that with it’s usage patterns vs Blaze, it is much harder to drive that out from the start of coding.

2 Likes

kk, sry for this stupid questions - i’m pretty new to meteor and just hoped to have a guideline for everything as long as the meteor guide isn’t for react :smile:

I just wanted to get started with testing in meteor and wondered why you aren’t using velocity in https://github.com/mantrajs/mantra-sample-blog-app - just a preference or is there some more reasoning?

Regards,
keep up this incredible work!

I can’t speak for Arunoda, but my experience with velocity has been that it is not very stable when it comes to running meteor tests on Continuous Integration tools (like TravisCI).

1 Like

A big reasoning.

I know Velocity team has a done a lot to make it’s awesome. But, now it’s in a very sad situation. (Many parts of it are not maintained now)

Velocity testing is very hard since you need to work with Meteor to run the test. In Mantra we handle this with unit-testing.

So, you don’t need to deal with Meteor to run tests. That’s a huge win.
We don’t work with E2E testing. For that, you can use some other standard projects to do E2E or something like Chimp.

1 Like

No one should use Velocity for any new frameworks. It is only a peg-leg solution until Meteor 1.3 is released.

@arunoda, I’m also looking at doing exactly the same, to have the ability to run unit tests using standard tools for all modules, so I’m excited to see what you come up with.

4 Likes

We did it with doing dependency injections and following some rules. We need some help with stubbing related tools. I think velocity had some auto-subbing tools.

1 Like

Can you compare how Mantra is different from Space?