andrewcarreiro / vscode-calculate

Calculation extension for Visual Studio Code
Do What The F*ck You Want To Public License
13 stars 10 forks source link

Visual Studio Code Calculate

About

Uses Math.js for evaluating expressions. If it works there, it should work here!

How to use

  1. Select an expression in your document. For example, ((((5*5)+1)/2)-10)^2
  2. Enter the Command Pallette (F1), and type "calculate"
  3. The evaluated result will appear after your selection

Counter

The $i in any selection is replaced by the index of the selection. For example if you have three identical selections 2*$i+1 the results will be 3, 5 and 7.

Selecting multiple items and running the calculate function

Available Commands

Acknowledgements

License

Copyright (c) 2018 Andrew Carreiro Licensed under the WTFPL license.