GithubHelp home page GithubHelp logo

cguille / codemirror-pastebin-chrome Goto Github PK

View Code? Open in Web Editor NEW
1.0 1.0 0.0 728 KB

"Provide a CodeMirror text editor on pastebin.com. Based on the work of Maxime (@EpocDotFr) : http://blog.epoc.fr/2013/09/01/codemirror-for-pastebin/

Shell 0.03% JavaScript 91.58% CSS 8.40%

codemirror-pastebin-chrome's People

Contributors

cguille avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

codemirror-pastebin-chrome's Issues

Editing area height

When CodeMirror is loaded, it reinitialize the editing area height to something like 300px : this is too tiny if you have more than 23 lines of code to edit.

I see four solutions :

  • On the CodeMirror initialization, set an arbitrary height (like 800px) : easy pick,
  • Create an input so the user can itself set the height of this area : easy pick,
  • Mimic the Pastebin behavior : dynamically set the height of the editing area regarding the number of lines, even if new lines are detected in the future : hard pick, but maybe CodeMirror provide a plugin / an API that do the trick,
  • On initialization, set a height of document.documentElement.clientHeight - 250 : easy pick. So no worry about coding a complex thing.

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.