Davide Bellone Profile picture
Jan 11, 2022 9 tweets 4 min read Read on X
As a #dotnet dev, when you need to run some throwaway code, you don't need to open an IDE, create a new console app, and discard the changes.

There are lots of tools you can use to run C# code in the bat of an eye.

Let's list some of them 🧵
1️⃣ LinqPad

It's a playground for running C#, F#, and VB code offline.

👍 run/debug code
👍 run XUnit tests
👍 save your snippets locally
👍 Well-printed object
👍 NuGet packages

👎 only local development
👎 free version does not tidy up your code

🔗 @linqpad Image
2️⃣ try[.]dot[.]net

Minimal online editor, supported by Microsoft

👍 Lightweight
👍 explicit 'using' list

👎 slow execution
👎 no NuGet package
👎 no sharing capabilities

🔗 @dotnet Image
3️⃣ dotnet-repl

Available on GitHub, run your code on a REPL terminal.

👍 Cool
👍 works with C# and F#
👍 free
👍 you can add NuGet packages

👎 on console, harder to write
👎 cannot save snippets Image
4️⃣ Sharplab

Available at Sharplab[.]io, run code to see the compiled result, IL, syntax tree

👍 good for advanced devs
👍 works with C#, F#, VB, IL
👍 can share code as GIST

👎 no code tidy up
👎 no NuGet packages Image
5️⃣ .NET Fiddle

Online editor, available at dotnetfiddle[.]net

👍 share and collaborate on code
👍 tidy up code
👍 NuGet packages
👍 choose compiler, language, project type
👍 converts your code to IL and VB

👎 no autocomplete

🔗 @dotnetfiddle Image
6️⃣ dotnet-script

Available on GitHub, run local scripts on a terminal.
Each script is stored in a .csx file.

👍 NuGet packages
👍 Lightweight
👍 save/organize your snippets locally

👎 no autocomplete
👎 no debug Image
7️⃣ RoslynPad

Available on GitHub and Windows Store, run programs locally

👍 NuGet packages
👍 Lightweight
👍 save/organize your snippets locally
👍 autocomplete
👍 format document
👍 completely free

👎 no debug Image
Do you use any of them?

Do you have other tools to suggest?

What are the must-have features for such tools?

• • •

Missing some Tweet in this thread? You can try to force a refresh
 

Keep Current with Davide Bellone

Davide Bellone Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

PDF

Twitter may remove this content at anytime! Save it as PDF for later use!

Try unrolling a thread yourself!

how to unroll video
  1. Follow @ThreadReaderApp to mention us!

  2. From a Twitter thread mention us with a keyword "unroll"
@threadreaderapp unroll

Practice here first or read more on our help page!

More from @BelloneDavide

May 31, 2021
An introduction to Unit Tests (UT), Mocks, Integration Tests (IT), End-to-end Tests (E2E).

Say that you want to learn how to drive. 🚗

[1/9]
At home, you have a car simulator.
Your Unit Tests will be:
🔸how to turn on the car
🔸how to speed up
🔸how to slow down
🔸what to do with a red light

You are not using a real car, but a simulator. This is your *mock*.

[2/9]
UTs: test the behaviors in a controlled environment with mocks.

They are fast: you can stay at home with your simulator. In a minute you'll be able to redo your tests and add more (eg: turn on the lights)

[3/9]
Read 9 tweets

Did Thread Reader help you today?

Support us! We are indie developers!


This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3/month or $30/year) and get exclusive features!

Become Premium

Don't want to be a Premium member but still want to support us?

Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal

Or Donate anonymously using crypto!

Ethereum

0xfe58350B80634f60Fa6Dc149a72b4DFbc17D341E copy

Bitcoin

3ATGMxNzCUFzxpMCHL5sWSt4DVtS8UqXpi copy

Thank you for your support!

Follow Us!

:(