Abstract
Programming in Clean is much more appealing than programming in JavaScript. Therefore, solutions that can replace JavaScript with Clean in client-side web development are widely welcomed. This paper describes a technology for the cross-compilation of Clean to JavaScript and for the tight integration of the generated code into a web application. Our solution is based on the iTask framework and its extension, the so-called Tasklets. The application server approach provides simple and easy deployment, thus supporting rapid development. Examples are shown to illustrate how communication between the Clean and JavaScript code can be established.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Preview
Unable to display preview. Download preview PDF.
Similar content being viewed by others
References
Abadi, M., Cardelli, L., Pierce, B., Plotkin, G.: Dynamic typing in a statically-typed language. In: Proceedings of the 16th ACM SIGPLAN-SIGACT Symposium on Principles of Programming Languages, POPL 1989, pp. 213–227. ACM, New York (1989)
Ashkenas, J.: List of languages that compile to JavaScript, https://github.com/jashkenas/coffee-script/wiki/List-of-languages-that-compile-to-JS
Cooper, E., Lindley, S., Yallop, J.: Links: Web programming without tiers. In: de Boer, F.S., Bonsangue, M.M., Graf, S., de Roever, W.-P. (eds.) FMCO 2006. LNCS, vol. 4709, pp. 266–296. Springer, Heidelberg (2007)
Dijkstra, A.: The Utrecht Haskell Compiler JavaScript Backend, http://uu-computerscience.github.com/uhc-js/
Domoszlai, L., Bruël, E., Jansen, J.M.: Implementing a non-strict purely functional language in JavaScript. Acta Univ. Sapientiae. Informatica 3(1), 76–98 (2011)
Domoszlai, L., Plasmeijer, R.: Tasklets: Client-side evaluation for iTask3 (2012), http://people.inf.elte.hu/dlacko/papers/tasklets.pdf
Done, C.: The FAY language, http://fay-lang.org/
Ekblad, A.: Towards a DeclarativeWeb. Master’s thesis, University of Gothenburg, Göteborg, Sweden (August 2012)
The Google Web Toolkit site, http://code.google.com/webtoolkit/
Lijnse, B., Plasmeijer, R.: iTasks 2: iTasks for end-users. In: Morazán, M.T., Scholz, S.-B. (eds.) IFL 2009. LNCS, vol. 6041, pp. 36–54. Springer, Heidelberg (2010)
Loitsch, F., Serrano, M.: Hop client-side compilation. In: Proc. 7th Symposium on Trends in Functional Programming, TFP 2007 (2007)
Moñino, M.C.: The Google Web Toolkit site, http://code.google.com/webtoolkit/
Nazarov, V.: The GHCJS Haskell to Javascript translator, https://github.com/ghcjs/ghcjs
Pil, M.: Dynamic types and type dependent functions. In: Hammond, K., Davie, T., Clack, C. (eds.) IFL 1998. LNCS, vol. 1595, pp. 169–185. Springer, Heidelberg (1999)
Plasmeijer, R., Lijnse, B., Michels, S., Achten, P., Koopman, P.: Task-oriented programming in a pure functional language. In: Proceedings of the 14th Symposium on Principles and Practice of Declarative Programming, PPDP 2012, pp. 195–206. ACM, New York (2012)
Tarditi, D., Lee, P., Acharya, A.: No assembly required: compiling standard ML to C. ACM Lett. Program. Lang. Syst. 1(2), 161–177 (1992)
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2013 Springer-Verlag Berlin Heidelberg
About this chapter
Cite this chapter
Domoszlai, L., Kozsik, T. (2013). Clean Up the Web!. In: Achten, P., Koopman, P. (eds) The Beauty of Functional Code. Lecture Notes in Computer Science, vol 8106. Springer, Berlin, Heidelberg. https://doi.org/10.1007/978-3-642-40355-2_10
Download citation
DOI: https://doi.org/10.1007/978-3-642-40355-2_10
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-642-40354-5
Online ISBN: 978-3-642-40355-2
eBook Packages: Computer ScienceComputer Science (R0)