Wire-webapp: Drop CoffeeScript

Created on 14 Mar 2017  路  26Comments  路  Source: wireapp/wire-webapp

We decided to slowly start moving away from CoffeeScript to JavaScript! As this step is impossible to do it in one go, here is the list of things needs to be done before we sign it off.

Tools that could help

Things to do

  • [x] Support JavaScript, along with CoffeeScript in the build scripts (#883)
  • [x] Add ESLint to build pipeline (#889)
  • [x] app/

    • [x] script/

    • [x] config.coffee (#888)

    • [x] announce/ (#899)

    • [x] assets/ (#912)

    • [x] audio/ (#925)

    • [x] auth/ (#947)

    • [x] bot/(#941)

    • [x] cache/ (#946)

    • [x] calling/ (#1125)



      • [x] Remove deprecated calling v2 code (#1340)



    • [x] client/ (#976)

    • [x] components/ (#1207)

    • [x] connect/ (#1030)

    • [x] conversation/ (#1172)

    • [x] cryptography/ (#1048)

    • [x] entity/ (#1195)

    • [x] entity/message (#1097)

    • [x] ephemeral/ (#950)

    • [x] event/ (#1078)

    • [x] extension/ (#1081)

    • [x] links/ (#963)

    • [x] localization/ (#1036)

    • [x] location/ (#951)

    • [x] main/ (#1084)

    • [x] media/ (#1065)

    • [x] message/ (#1086)

    • [x] properties/ (#1079)

    • [x] search/ (#1082)

    • [x] service/ (#1080)

    • [x] storage/ (#1083)

    • [x] system_notification/ (#1052)

    • [x] telemetry/ (#1089)

    • [x] tracking/ (#1085)

    • [x] ui/ (#1120)

    • [x] user/ (#1138)

    • [x] util/ (#1114)

    • [x] view_model/ (#1236)



      • [x] view_model/bindings/ (#1222)


      • [x] view_model/content/ (#1235)


      • [x] view_model/list/ (#1233)



    • [x] worker (#1374)

  • [x] test/api
  • [x] test/unit_tests/ (#1201)

    • [x] announce/ (#1201)

    • [x] assets/ (#1201)

    • [x] audio/ (#1201)

    • [x] auth/ (#1201)

    • [x] cache/ (#1201)

    • [x] calling/ (#1201)

    • [x] client/ (#1201)

    • [x] connect/ (#1201)

    • [x] conversation/ (#1201)

    • [x] cryptography/ (#1201)

    • [x] entity/ (#1201)

    • [x] event/ (#1201)

    • [x] extension/ (#1201)

    • [x] links/ (#1201)

    • [x] localization/ (#1036)

    • [x] location/ (#951)

    • [x] media/ (#1201)

    • [x] message/ (#1201)

    • [x] search/ (#1201)

    • [x] service/ (#1201)

    • [x] storage/ (#1201)

    • [x] system_notification/ (#1201)

    • [x] tracking/ (#1201)

    • [x] ui/ (#1201)

    • [x] user/ (#1201)

    • [x] util/ (#1201)

    • [x] view_model/ (#1201)

  • [x] Gruntfile.coffee (#885)
  • [x] grunt/config/ (#1376)
  • [x] grunt/tasks/ (#1376)
  • [x] Make sure there are no *.coffee files in the project
  • [x] Remove build tasks package.json
  • [x] Remove the CoffeeScript dependency from package.json

Most helpful comment

Thanks for sharing this. Haven't followed the whole v2 discussion. Was quite surprised to see that they actually started working on this finally. But this doesn't change our decision. What you mentioned is similar to what we discussed. Besides that some more reasons from our site are:

  • We only support recent browser versions which can handle es6. So we can get rid of a compile step and start writing plain es6. Using babel on top is also easier with this setup.
  • We had some nasty bugs because of implicit returns
  • Interoperability with other frameworks and tooling. People putting less and less effort to support CoffeeScript (e.g React esp. JSX)

To sum it up. CoffeeScript introduced some really helpful concepts and made coding more convenient, but JavaScript nowadays offers so much more.

All 26 comments

Not sure what the reasoning is, but CoffeeScript v2 will be out soon: https://github.com/coffeescript6/discuss/issues/71

Over at Bevry, we moved from CoffeeScript to ESNext for all our things throughout 2016. Our reasoning is at: https://discuss.bevry.me/t/move-from-coffeescript-to-es6/30/1 - perhaps will have some useful resources for your own move.

Thanks for sharing this. Haven't followed the whole v2 discussion. Was quite surprised to see that they actually started working on this finally. But this doesn't change our decision. What you mentioned is similar to what we discussed. Besides that some more reasons from our site are:

  • We only support recent browser versions which can handle es6. So we can get rid of a compile step and start writing plain es6. Using babel on top is also easier with this setup.
  • We had some nasty bugs because of implicit returns
  • Interoperability with other frameworks and tooling. People putting less and less effort to support CoffeeScript (e.g React esp. JSX)

To sum it up. CoffeeScript introduced some really helpful concepts and made coding more convenient, but JavaScript nowadays offers so much more.

screen shot 2017-04-06 at 16 11 51

screen shot 2017-04-07 at 22 42 11

screen shot 2017-04-12 at 12 05 59

screen shot 2017-04-12 at 13 59 22

screen shot 2017-04-18 at 20 04 04

coffeescript

unbenannt

Screenshot

stuff

Finally 馃槃

unbenannt

screen shot 2017-05-09 at 22 30 05

screen shot 2017-05-09 at 22 24 42

js

screen shot 2017-05-11 at 18 45 19

js

js

Another milestone passed 馃帀

js

js

B盲盲m

bildschirmfoto 2017-06-12 um 17 44 54

DONE!

KAPUT!

Now i should start drinking less coffee -_-'

but but but Java is Coffee 馃棥

Let's have a celebration tonight 馃帀

Was this page helpful?
0 / 5 - 0 ratings