Live data from Hacker News

Excel Adds JavaScript and Power BI Support

dev.office.com

101–108 of 108 posts

Re: Excel Adds JavaScript and Power BI Support

#101

Earlier quoted context omitted.

Hi, I'm the PM for the feature. Thanks for this feedback about TypeScript support! I totally agree that TypeScript is ideal for this use case. As other commenters have mentioned, we want to stay flexible for everyone, whether or not they use TypeScript. We'll provide support to make the TypeScript development experience great, like type definition files. You can compile any TS files to JS at development/deployment ti…

I'm the kind of person this is directly aimed at, finance background, Excel officionado begging for a better scripting language. I can tell you that I am not interested in js for Excel one bit. Python for Excel however...

We did announce (but not yet release) custom Azure Machine Learning functions in Excel. I mention in the blog that since Python runs on Azure ML, you'll be able to run custom Python functions in the cloud, as part of Excel formulas[1].

That announced Azure ML feature is optimized for machine learning models (in terms of the tools/deployment/runtime we've provided), so even though it will work for any Python functions it might not be exactly what you're asking for. Also, depending on your specific use case, you may or may not need client-side execution (Azure ML functions run in the cloud today). I can't share specifics on other unannounced features, but Azure ML functions are only our first foray in this space: we think custom functions running in the cloud are very important for many different use cases in Excel.

Also, note that on the JavaScript side, the language choice isn't something new for Excel or Office: for example, there's a public ecosystem of add-ins that automate Excel via JavaScript today[2]. Custom functions are just the latest way we've enabled for extending Excel as part of an add-in[3].

[1] https://dev.office.com/blogs/azure-machine-learning-javascri... [2] https://appsource.microsoft.com/en-us/marketplace/apps?produ... [3] https://docs.microsoft.com/en-us/office/dev/add-ins/excel/ex...

Re: Excel Adds JavaScript and Power BI Support

#102
post #47

A bit surprised that there's no TypeScript support, especially considering how verbose metadata you have to write as a result[1]. That whole thing could be made much simpler with some TS and JSDoc, eg. /** * adds 42 to the input number * @param a the first number to be added * @param b the second number to be added */ function ADD42(a: number, b: number): number { return a + b + 42; } [1] https://docs.microsoft.com/e…

Because... this is no support for TypeScript in native JS runtimes? It would add to complexity if you introduce a compilation step before executing them in JS runtime, especially when you are targeting multiple platforms.

That's hardly a problem. Since they can run JS, they could just add the TypeScript compiler itself into Excel and compile code on demand (and cache the results).

Re: Excel Adds JavaScript and Power BI Support

#103

Earlier quoted context omitted.

So my question is how this integrates with their online version of Excel? For example: I build some custom JS based functions in Excel and used them all over my spreadsheet then I upload it to OneDrive and trying to open it in online Excel form, will it work? That is key for someone like me who creates sheet offline but then wants to consume the data via online version.

As the PM for this feature I'm happy to answer that it works in Excel Online starting today in the developer preview! Right now developers have to sideload the add-in manually. But when the feature ships publicly, the add-in that has the custom JS functions will be deployed to a "catalog". The various Excel platforms (like Excel for Windows, Mac, and Excel Online) will all be able to access that catalog automatically…

It would be wonderful if it were possible to integrate with this 'pointer' mechanism in a custom way for .xll add-ins too, like those made in C/C++, .NET (with Excel-DNA), Python (with PyXLL) or D (with excel-d)? There's a huge ecosystem of Excel add-ins that could benefit by access to just a few of the hooks being build for the JavaScript support.

Re: Excel Adds JavaScript and Power BI Support

#104

Earlier quoted context omitted.

Hi, I'm the PM for the feature. Thanks for this feedback about TypeScript support! I totally agree that TypeScript is ideal for this use case. As other commenters have mentioned, we want to stay flexible for everyone, whether or not they use TypeScript. We'll provide support to make the TypeScript development experience great, like type definition files. You can compile any TS files to JS at development/deployment ti…

I'm the kind of person this is directly aimed at, finance background, Excel officionado begging for a better scripting language. I can tell you that I am not interested in js for Excel one bit. Python for Excel however...

Have you given PyXLL a try?

Re: Excel Adds JavaScript and Power BI Support

#105

Earlier quoted context omitted.

Well, on the one hand, it's not a problem. It's pure elitism to insist that laypeople learn Real Programming and make their spreadsheets the Right Way. Excel + JS is going to be an empowering tool. But on the other hand, it's going to be a nightmare to maintain when you layer it on top of VBA macros, and some poor soul is going to end up responsible for making it continue to limp along. Nobody will understand how it…

I don't think this worry comes out of elitism. On the contrary, I think it comes from trying to protect the business users - as messy as their tooling already is - from the JavaScript culture .

> My language has good culture, JavaScript has bad culture

I think you failed to move the goalpost away from elitism.

Re: Excel Adds JavaScript and Power BI Support

#106

Earlier quoted context omitted.

I don't think this worry comes out of elitism. On the contrary, I think it comes from trying to protect the business users - as messy as their tooling already is - from the JavaScript culture .

> My language has good culture, JavaScript has bad culture I think you failed to move the goalpost away from elitism.

Well, if you want particulars - my favourite language has plenty of cultural problems, like huge NIH syndrome, or complete inability to actually finish a library (and don't get me started on documentation...). But JavaScript seems to have an unique cultural combination of "move fast and break things" coupled with complete disregard for any kind of efficiency considerations. I don't want to see the web bloat ported over to spreadsheets too.

Re: Excel Adds JavaScript and Power BI Support

#107

Earlier quoted context omitted.

> My language has good culture, JavaScript has bad culture I think you failed to move the goalpost away from elitism.

Well, if you want particulars - my favourite language has plenty of cultural problems, like huge NIH syndrome, or complete inability to actually finish a library (and don't get me started on documentation...). But JavaScript seems to have an unique cultural combination of "move fast and break things" coupled with complete disregard for any kind of efficiency considerations. I don't want to see the web bloat ported ov…

You're making hasty generalization. JavaScript isn't one big homogeneous culture. I've never worked on a team where unnecessary library bloat and disregarding efficiency was acceptable. I've been to plenty of websites that reject that attitude. Usually businesses don't want to pay the extra dev hours (or quality dev rates) to get code optimized to my preferences.

Re: Excel Adds JavaScript and Power BI Support

#108

Earlier quoted context omitted.

It's called Jupyter

Jupyter has too much syntax for end users, and its execution model (having to run cells in order to prepare the state for executing other dependent cells) is not intuitive. Also, installing it is not exactly user friendly. Heck, you have to open a terminal to launch it!

[deleted]
Post reply on HN