DEV Community

Cover image for Eclipse Theia - 方便客製化的IDE
Jain Wun
Jain Wun

Posted on

4 3

Eclipse Theia - 方便客製化的IDE

訂閱patreon即可看到更多文章 https://www.patreon.com/wade3c
Youtube頻道 https://www.youtube.com/c/增廣建文


專門為了網頁瀏覽器而生的開源IDE,跟VScode的作法剛好相反過來

像是著名的Gitpod平台使用的就是Eclipse Theia (Gitpod後期有超多IDE可選)

image.png

整體介面會和VScode十分的雷同

Install

一開始推出主要focus在網頁瀏覽器上使用,後來也有推出用electron包的desktop版

Docker

由於官方比較建議使用Blueprint來包成desktop app

目前dockerhub上的官方image已經被下架,需要自己build或是找第三方

https://github.com/theia-ide/theia-apps#theia-docker

他比code-server的image好,有為了一些語言先打包好對應環境的docker image

Editor Only (Web Dev)

預設使用的port是3000

docker run -d -p 3000:3000 -v "$(pwd):/home/project:cached" elswork/theia
Enter fullscreen mode Exit fullscreen mode

Gitpod

對於Gitpod想要有更多了解的話可以參考 Gitpod

相較於docker image並沒有維護了,for Gitpod的Dockefile倒是還有在維護

可以在自己架的Gitpod平台或是官方架好的去測試

Gitpod.io

如果用的是Gitpod官方架的平台

直接點 https://gitpod.io/#https://github.com/eclipse-theia/theia 就可以開始體驗了

由於他這時是開發模式所以還需要下指令去啟動IDE (以前打開就會是theia介面,現在是VScode)

yarn browser start ../.. --hostname 0.0.0.0
Enter fullscreen mode Exit fullscreen mode

Build Your Own

透過修改Dockerfile可以建立適合自己的開發環境,撰寫js的話則可以達成客製化的IDE

Eclipse Theia Blueprint

讓你可以實作自己會用到的桌面app,這也是Eclipse Theia包成desktop app的方法

使用的環境並不限定一定要在實體機器上,依舊可以在docker內進行開發

未來會逐漸取代過往使用的electron


Reference

Theia - Cloud and Desktop IDE Platform

theia/Developing.md at master · eclipse-theia/theia

Sentry image

Hands-on debugging session: instrument, monitor, and fix

Join Lazar for a hands-on session where you’ll build it, break it, debug it, and fix it. You’ll set up Sentry, track errors, use Session Replay and Tracing, and leverage some good ol’ AI to find and fix issues fast.

RSVP here →

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay