Giter VIP home page Giter VIP logo

docs's People

Contributors

akkartik avatar alexmarchant avatar austinlyons avatar beilharz avatar cmontella avatar dependabot[bot] avatar eobrain avatar gamebox avatar ibdknox avatar ibdthor avatar joshuafcole avatar matthiaslange avatar mpj avatar pragmatrix avatar shamrin avatar

Stargazers

 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

docs's Issues

Add missing functions

Math Functions

  • +
  • -
  • *
  • /
  • log
  • exp
  • sin
  • cos
  • tan
  • asin
  • acos
  • atan
  • atan2
  • sinh
  • cosh
  • tanh
  • asinh
  • acosh
  • atanh
  • floor
  • ceiling
  • abs
  • mod
  • pow
  • random
  • range
  • round
  • gaussian
  • to-fixed
  • pi
  • e
  • ln2
  • ln10
  • log2e
  • log10e
  • sqrt1/2
  • sqrt2
  • sum
  • count
  • average
  • min
  • max

String Functions

  • join
  • split
  • substring
  • convert
  • urlencode
  • length

Misc

  • lookup
  • toggle

Make docs static site re-build automatically

The source for the docs is on docs/master, and the actual docs site is on docs/gh-pages. Currently I rebuild the site manually using Hugo, which uses docs/master as the source, and then I upload the output to gh-pages. What I would like is that every time I update docs/master, a script runs the hugo process and then updates docs/gh-pages with the output.

I'm aware this process is available by default for Jekyll, but I found Jekyll inadequate for doing a docs site, as it seems better suited for blogs.

Database doc page missing some basic concepts

I would make a pull request but I don't understand fully how they work. It seems implied in various place that "databases" are created on demand/ or they are just arbitrary namespaces. It would be great if that were explicitly stated.

A full list of built in databases would be nice too. I believe the http database is one that is missing from the standard lib.

Document handling counting 0 things

From: https://groups.google.com/forum/#!topic/eve-talk/VPPiMg1uZgw

The problem

I wanted to display a message if a particular tag was missing from all of a given set of records and thought I might be able to use the count function and match when it returns zero. However, I couldn't find a way to get it to return zero. In cases where I expect it to return zero, instead it doesn't match. Does it have to be that way?

Test data

commit
  [#item id: 0 #sorted]
  [#item id: 1]

Can get a count when there is a match

search
	c = count[given: [#item #sorted]]
bind @browser
	[#div text: "sorted count: {{c}}"]

Get empty results rather than count of zero for missing tag

search
	c = count[given: [#item #missing-tag]]
bind @browser
	[#div text: "missing tag count: {{c}}"]

Same for missing attribute

search
	c = count[given: [#item missing-attribute: true]]
bind @browser
	[#div text: "missing-attribute count: {{c}}"]

The solution

search
	total-sorted = if c = count[given: [#item #sorted]] then c
                              else 0
	total-unsorted = if c = count[given: [#item not(#sorted)]] then c
                                  else 0
bind @browser
	[#div text: "sorted count: {{total-sorted}}"]
        [#div text: "unsorted count: {{total-unsorted}}"]

Add search capability to docs site

Now that the number docs is increasing, mainly due to added functions, a search feature should be added to easily find what you're looking for. Unfortunately, the site is static HTML, so I don't know how search will work in that context.

Incorrect documentation for trigonometric functions

The documentation for sin, cos and tan currently states that the accepted attributes are:

  • degrees
  • radians

But in the current version of Eve the functions only accept the attribute "angle" (to my knowledge). I would guess that it is Eve and not the docs that needs updating.

(Also in math.md the word "arithmetic" is misspelt).

Rename join to concat

It seems "join" was renamed to "concat" at one point, that should be reflected in the docs.

I don't understand how concat is meant to work, any attempts i did only result in builder complaining that it can't find the AttributeMapping (because there isn't any defined in string.ts).
Can concat actually be used in it's current state?

Various typos in the Eve language handbook

I like Eve very much and worked through the Quickstart and handbook. I noticed a number of typos, most of them only spelling, a few in code examples itself. While "it is low hanging fruit", correcting them will give new users an even better experience, so I list them here:

(1) http://docs.witheve.com/handbook/is/
“The output shows that y is false while z is true.”

This is incorrect, the output is false and 10.
The code should be rewritten as: [#div text: "z is {{z}}"]

(2) Typo:
http://docs.witheve.com/handbook/functions/

“Also like records, arguments are stateted explicitly.”
Should be:
“Also like records, arguments are stated explicitly.”

angles in randians
should be:
angles in radians

(3) tictacto.eve:
product of their values. This means that if i = {0, 1, 2} and j = {0, 1, 2}, then i x j = {(1, 1), (1, 2), ... (3, 2), (3, 3)}. These are exactly the indices we need for our grid!

Should be: This means that if i = {1, 2, 3} and j = {1, 2, 3},

(4) http://docs.witheve.com/handbook/records/
Records are the predominate datatype in Eve
Should be:
Records are the predominant

(5) http://docs.witheve.com/guides/style/
Still uses match instead of search in:
// Good
match
[...]

bind
[...]

(6) Quickstart example:
search
schools = [#school address]
students = [#student school: school.name]

bind @browser
[#div text: "{{students.name}} attends {{schools.name}} at {{address}}"]

students = [#student school: school.name]
should be:
students = [#student school: schools.name]

(7) Quickstart:

celia = [name: "Celia"]
Uses the wrong double quotes character " from Word probably; which can give wrong program execution. This occurs at several places, it

(8) Quickstart: This block selects all students, and uses and if-then expression to set the student's
Should be an

(9) Quickstart:: calculated-age = if student.age then student.age
else if student.grade then student.grade + 5

Why so complicated and not just:

calculated-age = if student.grade then student.grade + 5
(10) http://docs.witheve.com/handbook/records/

commit
[name: "Jeremey" spouse: [name: "Wendy"]]

"Jeremey" should be "Jeremy"

(11) http://docs.witheve.com/handbook/not/

friends not invited to the party
friends = [#friend]
not(friends = [#invited])

should be: // friends not invited to the party

(12) http://docs.witheve.com/handbook/joins/:
joins allow you to relate two records

(13)
http://docs.witheve.com/handbook/math/floor/
search
y = floor[value: 34.2]

bind @browser
[#div text: value]

Should be:
bind @browser
[#div text: y]

(14)
http://docs.witheve.com/handbook/bind/

Display a formatted time:
match
[#time hours minutes seconds]
(am/pm, adjusted-hours) = if hours >= 12 then ("PM", hours - 12)
else if hours = 0 then ("AM", 12)
else ("AM", hours)
match should be search

(15) http://docs.witheve.com/handbook/functions/
[#fn #function argument1, ... argumentN, value1, ..., valueN]

Should this not be: [#fn #function argument1: value1, ... argumentN: valueN, return: value]

(16) http://docs.witheve.com/handbook/functions/
The example in Set Semantics is correct, but does not illustrate any function, merely string embedding. It belongs probably in the docs for sets.

(17) http://docs.witheve.com/handbook/if-then/
In the syntax format: (value, ..., valueN) should be (value1, ..., valueN)

[@"my party" date]
Should be [#"my party" date]

burgers = if guest = [@Arthur] then 3
should be #Arthur (2 x)

Explanations from Description should be written between the examples.

(18) http://docs.witheve.com/handbook/string-interpolation/
eacother should be each other

(19)
http://docs.witheve.com/handbook/add/
then := will create should be then += will create

(20) http://docs.witheve.com/handbook/action-phase : page does not yet exist

(21) the link time on http://docs.witheve.com/handbook/datetime/ does not work

(22)

http://docs.witheve.com/handbook/math/
Arithemtic
Should be
Arithmetic

(23)
In Eve 0.2.2; Idem fix, tan

(24) http://docs.witheve.com/handbook/math/mod/
The example code does not have an output because of [#angle value]
Replace by value = 30 for example.

(25) http://docs.witheve.com/handbook/math/range/
The { } notation is used for sets instead of ( )
y = {1, 3, 5, 6, 9} should be y = (1, 3, 5, 7, 9)

(26) http://docs.witheve.com/handbook/statistics/count/
he pervious example

(27) http://docs.witheve.com/handbook/statistics/random/
First example for random does not display anything, should be replaced by something like:

search
[#time minutes seconds]
x = random[seed: seconds]

commit @browser
[#div text: "{{minutes}} {{seconds}} - random: {{x}}"]

2nd example: should be: bind @browser
Same for 3rd example

(28) http://docs.witheve.com/handbook/strings/join/
takes tokens tokens together  redundant tokens
or should be: token tokens

(29)
// Join the tokens into a sentence again, with hyphens
search
[#token token index]
text = join[token, index, with: " "]
bind
[#div text] // Expected "the-quick-brown-fox"
 There is no definition for the function join

(30) http://docs.witheve.com/handbook/glossary/
Glosasry should be Glossary
Referential Transparentcy should be Referential Transparency

Thanks!

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.