Giter VIP home page Giter VIP logo

Comments (5)

kbrsh avatar kbrsh commented on May 21, 2024

You can, but that is not what a computed property is for. You can use a method like this:

<p>{{add(1, 3)}}</p>
<button m-on:click="add(1, 3)"></button>
methods:  {
  add: function(a, b) {
    return a + b;
  }
}

Computed properties are used for values that depend on others.

EDIT: You will be able to do this in v0.9.0 (hopefully coming out today)

from moon.

adekoyejoakinhanmi avatar adekoyejoakinhanmi commented on May 21, 2024

Oh ok...I super excited for v0.9.0. Can't wait to try out the new features. I am currently building the tweetbox from "A Vue.js introduction for people who know just enough jQuery to get by" but I am using MoonJS. Would share as soon as I am done.

from moon.

kbrsh avatar kbrsh commented on May 21, 2024

Awesome! Can't wait to see it 👍

I'm in the process of releasing v0.9.0 right now, just fixing up the docs.

from moon.

adekoyejoakinhanmi avatar adekoyejoakinhanmi commented on May 21, 2024

KingPixil -- Already using v.0.9.0 and it's really awesome. Well done. Here is the link to Moon Tweet box.

from moon.

kbrsh avatar kbrsh commented on May 21, 2024

@adekoyejoakinhanmi Thank you! I'm super glad you like it! Also really love the tweet box 🙌

from moon.

Related Issues (20)

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.