Code Monkey home page Code Monkey logo

damsel's People

Contributors

dskinner avatar

Stargazers

 avatar  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

damsel's Issues

is % really necessary?

In the py project, it certainly was for differentiating a line of python from html.

x = 5
%p {x}

It also enabled inlined tags

%html %body %h1 Hello World

The three options in my mind worth considering are

Remove From First Element

Due to how plain text works right now, the line contained by the element needs no special notation, but multiline plain text requires a back slash, mostly to properly control whitespace. It is feasible to not require % except for inlining

html
  body
    div %h1 Hello World
    div a b c d
      \ e f g

I feel this is a bit hard to distinguish whats going on though. Which brings me to the other option

Swap control needs from elements to text

Essentially, remove the need for % and require something for all text. The example below uses \

html body
  div \ a b c d
    \ e f g h

Considering the use case of damsel (discussed below) this wouldn't be a bad option, but I do feel it might become more burdensome to seemingly arbitrarily insert a character to start text mid declaration versus the somewhat easy habit of starting a new line with %. A % also gives each element a distinct look, such %div #id .class

Finally, this brings me back to

Leave it alone

Something like damsel suits a particular need of development, and that need is not for large content writeups. It's ideal for stubbing out an interface that will have most of its content insert by variables, and heavily scripted by javascript, making it easy to reference the dom you've created. I already feel the syntax accomplishes that through my use of it on multiple projects. If the constraints I worked under at the time just happen to produce the best results I can come up with, then it may be best to simply leave it alone.

compile problem

cd github.com/dskinner/damsel/
go install
main.go:7:2: import "dasa.cc/damsel/dmsl": cannot find package
main.go:8:2: import "dasa.cc/damsel/dmsl/parse": cannot find package

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.