Sharepoint - SPFx: Is TypeScript compulsary for future SharePoint development?

Short answer - no, it's not required.

Longer answer - The toolchain we'll provide and invest in will be TypeScript based, as that is what we use internally for our own work, and we've found that it is better for us to focus on one solution than spread out across many. That said, the plan is to

a) create additional documentation on what the final output of the toolchain needs to look like, and

b) enable the ability to plug different tasks into the build pipeline.

Those tasks could allow you to use ES6 for example, rather than TS. You could even, technically, use notepad to hand craft a pure .js file and a manifest.json file, with no toolchain at all.

As for "let everyone go and hire new people", I think that's a bit silly. Sure, you need to learn a new tech, but all the technical domains (SharePoint, javascript, HTML, CSS, etc.) are all the same. As Sebastian mentions, it might take a short while, but it's completely learn-able.


SPFx development can only be done with (thorough) TypeScript knowledge (and the whole dev stack)

No I have gone from no knowledge to producing proof of concept code for a relatively complex scenario (export search results to CSV) in a week.

The 'whole' dev stack is not too bad but you will need to understand npm, gulp, typescript and preferable REACT. The tutorials are good.

Any external library (eg. 3rd party jQuery libraries) needs .d.ts definition declarations

Yes but most of them have these already and even if not they are fairly simple to write yourself.

https://github.com/typings/typings is your friend as its a community project that has lots of support for third party libraries.

3rd party ES5 Libraries that are not strongly typed and interact out of their box (into DOM) might cause problems

Yes but again you need to be thinking about using frameworks instead, SPFx shines when used with REACT / Angular because that's how its constructed.

Third party libraries that directly edit the DOM won't cause SPFx problems but they are not a good idea generally (see https://facebook.github.io/react/docs/thinking-in-react.html for an better explanation).

Its cheaper to 'let the team go' and find people with above skills

No if they have JavaScript and an appetite to learn then I'd say a week is what you need to get up to speed. Building relationships with new people and learning to trust each other takes much longer.

  1. Do the React Tutorial first (its quick and gentle)
  2. Do the SPFx Tutorial next
  3. Cut code

Hope this helps

Sebastian


Answer to the headline question: no, but for SharePoint Framework it's going to help a lot (see @patmill-msft answer).

If they are good developers they will have no problem learning TypeScript, and it will be a worthwhile investment for productivity. A thorough knowledge of the stack is necessary to be a good developer generally, in my opinion.

Without the d.ts files you won't get Intellisense in VS Code (and before someone asks, yes, you could of course use another editor if you prefer).

TypeScript "transpiles" to JavaScript; there's nothing special or "strongly-typed" about the output of the transpiler, and nothing to do with DOM interaction which is a separate issue.

If you have a good development team, it would be cheaper to invest time for them to acquire new skills, but this should be an ongoing process anyway as the technology is constantly changing.

Tags:

Spfx