Hi, my name is Matthew Zeng,
aka MT or Mingde.
Welcome to EmacsConf2021.
I hope everyone is enjoying
the conference so far.
I am one of the maintainers
of the Emacs Application Framework.
I was also here last year during EmacsConf2020
and did a 20 minute presentation
on the overall architecture of EAF
as well as a small demo.
A lot of things had changed since 2020,
and that's why today I'm here to present:
Emacs Application Framework, A 2021 Update.
So we all know Emacs,
and we definitely know that
Emacs is not just a text editor,
but a text-centric work environment,
and it lacks *efficient*
multimedia rendering capabilities
such as website, PDF, and video rendering.
We all want that, right?
Therefore the EAF project wants to
solve this problem while also
retaining the rich Emacs ecosystem
and its customizability and extensibility.
The solution is to outsource the hard part
to Python and NodeJS
by bridging Elisp with them
so that Python and JavaScript
can do the hard work
and minimize the Elisp workload,
which ultimately speeds up
our end-user experience using Emacs.
Do note that Python and JavaScript
already have a very mature ecosystem
that provides a foundation
to modern multimedia applications,
so basically, EAF enables Emacs to extend
to Python and JavaScript ecosystems,
therefore extending to
modern multimedia apps too.
As we're on a tight schedule today,
I can't go into every detail
about how EAF achieves this.
I did go through a lot of things
during last year's presentation,
so I highly recommend anyone interested
to check out that presentation,
and the project repository itself.
Today we're focusing on *what changed*.
Now the first change
that you'll definitely notice
is that we have a new logo!
This logo uses gearwheels
to symbolize how EAF extends Emacs
to web and multimedia applications
that bring new possibilities to Emacs.
Since last year, EAF has replaced
the DBus communication technology
with the cross-platform EPC,
the Emacs RPC stack,
which has an Elisp implementation
and a Python implementation,
exactly what we need.
This and some other changes
enable EAF to support Windows,
Windows 10 and Windows Subsystem for Linux,
as well as all distros that support
pacman, apt, dnf, pkg,
zypper package installer commands,
which includes Arch-based, Debian,
or Ubuntu-based, Fedora, etc.
However, do note that the maOS support
works with some known issues.
Have a look if you want to try out.
Previously, EAF was able to make Elisp
communicate with Python, as well as
Python to communicate with JavaScript,
meaning that Elisp can call
Python functions and vice versa,
and Python can call JavaScript functions
and vice versa, but if you want Elisp
to communicate with JavaScript,
you have to go through Python,
which is rather troublesome.
Now, thanks to the EPC,
Elisp can communicate
with JavaScript directly
using =eval_js= function
and =eval_emacs_function=
in Elisp and Python respectively.
This greatly simplifies the code
that will be needed
to write a web app in EAF.
Speaking of web applications,
VueJS is a web framework
that's been gaining a lot of popularity
in recent years
for its simplicity and functionality.
In the past, you were only able to write
simple JavaScript and HTML web apps
for EAF. It was quite some work
to create a full-featured web application.
Now you can write new apps using EAF
that work seamlessly with Emacs and Elisp.
There are a few existing EAF apps
written with Vue already
to demonstrate the possibilities
of Vue-based extensions in Emacs.
The first one is the EAF File Manager,
written by ManateeLazycat himself,
as an alternative option to dired,
as he found dired's performance
to lag considerably
when there are way too many files.
It supports wdired and fd functionality,
and let me demonstrate that to you.
See? And this is the app.
Go back here.
Another one is the EAF RSS Reader,
written by our Summer of Code 2021 student
ShaoChenHeng. It is a fast RSS reader
that uses the EAF browser for previews,
and let me demo that to you as well.
Pragmatic Emacs.
And you can view every site
in the EAF Browser.
To ease the process
of creating a new EAF application,
we've separated the EAF core and its apps,
so that EAF apps now have
their individual repositories.
You can find them under
the emacs-eaf GitHub organization.
Because of the number of EAF apps
and their dependencies
that vary from system to system,
we've also introduced a new
=M-x eaf-install-and-update= command
which is a wrapper around the new
install-eaf python script
dedicated to installing, updating,
and maintaining EAF apps
and their dependencies
for the end user.
Now it is very easy
to create a new EAF app.
You just need to do it.
You can just do it in your own repository,
such as in GitHub, GitLab, or wherever.
The first thing to do is
to fork the eaf-demo or the eaf-vue-demo
as a starting template,
then update the dependencies.json file
to list the new dependencies you introduced
on various systems.
Afterwards, once your app is finished,
you simply need to submit a PR
to the EAF core
that modifies the applications.json list
to include your new app. And that's it.
Come try it out and write your own
EAF extensions today!
There are many other new updates.
To list a few: we reached
more than 60 contributors, hooray!
And also, you can now use the familiar
Control s and Control r isearch
for real-time search,
functioning very similar
to the Emacs isearch,
in the EAF Browser, PDF Viewer,
and many other applications.
Additionally, you can also create
EAF PDF annotations
either inline or as a pop-up, etc. etc. etc.
Finally, let's talk about Popweb.
Popweb is a very, very new project
that started like exactly two weeks ago,
that focuses particularly on the
multimedia pop-up functionality in Emacs.
Pop is considered to be a sister project
and lightweight version of EAF.
They both share a very similar design
and some code, and they are maintained
by the same people,
which is me and ManateeLazycat.
Here's a quick demo to see the
responsiveness of its preview.
Here we go. On the right, see...
Oh, here we go. Yes.
And these are the LaTeX preview.
I can quickly show the next one.
So this is the end of my presentation.
Feel free to post questions
on the collaborative pad, IRC,
or directly send me an email.
I'll be around all this,
at all these places,
and if you found any issue,
please submit an issue
to the EAF official issues,
and don't forget to check out the wiki.
Thank you and enjoy
the rest of EmacsConf 2021.
[captions by sachac]