Strapi hosted a virtual meetup last week for everyone interested in the open-source headless CMS to learn more about the latest releases and new features.
May 7, 2020
Moving fast and evolving to better fit all needs has everyone at Stapi working hard to add the best of the best to the open-source headless CMS. Keeping up with every change and understanding whether or not an update is important for your specific use case is important, but sometimes difficult to fit into the schedule.
To make all that easier and open up a platform to ask questions, Virginie Ky, Frontend Engineer, and Alexandre Bodin, Engineering Lead, hosted a virtual meetup last week, inviting everyone interested in Strapi to learn more about the latest releases and new features.
Here's a few numbers to start:
If you missed the webinar, well you’re in luck! You can watch the video of the full event and follow along the useful demos for each new feature:
The new Single Types were a significant improvement over using Collection Type to create static content. Along with adding a new data structure, it allows for easy management of one specific instance of data while maintaining the ability to switch between Collection Type and Single Type.
The end result for most people is a simplified process for creating a home page or a portfolio page or any other kind of page!
The new UID field provides a unique identifier for any given entry, paving the way for Collection Types to have specific and unique identifiers for each of their entries as well. A direct result of that process is readily having access to unique strings that can then generate SEO-friendly URLs.
In other words, the new UID field provides easier access to human-readable (and more memorable) URL slugs that can replace randomly generated ids.
The story of the new Media Library starts with the Strapi product board. After noticing a strong desire for a cohesive and complete Media Library feature, the team got to work and wanted to make sure it would meet the needs of the community.
Going one step further for such a huge new feature, the team also asked all Strapi users to answer a survey about what exactly they would want to see in the Media Library. While it differed from the initial ideas on the product board, that only helped shape a more complete and user-friendly feature for the final release.
After covering Single Types, UID Field, and the Media Library, Virginie and Alexandre opened up the conversation, giving time for anyone attending to ask questions.
With Strapi fans joining in to share their personal stories and professional use cases, the end of the meetup turned into a fun moment of exchanging ideas on how best to unleash content with Strapi.
Read on for a transcript of all the questions asked with answers from the Strapi team!
1) Do images retain their original names after being uploaded to the Media Library?
Yes, when you select a file from your computer and upload it to the Strapi Media Library it keeps its original name. However, it will be cleaned up a bit, removing spaces and standardizing the style. After that Strapi puts a hash at the end of the name so it has a unique ID and that’s basically it.
You can also always change the display name to whatever you want in the Media Library.
2) Can you define the alt text for images in the Media Library?
Yes, you can add alternative text to images and it’s easy to see all the available options in the API. Alt text, captions, and more are all a part of the standard API call and are easy to set in the Media Library.
If you upload an image that Strapi can’t process for some reason, you’ll see a smaller thumbnail and an error message saying there are too many images loading in the browser.
Generally, everything is well optimized and when uploading very large images, you’ll also have the option to choose specific sizes (small, medium, or large), and you can automatically use them for a more responsive user experience.
3) Is the AWS s3 plug-in no longer necessary to upload files to AWS s3?
All provider plugins still work and of course you can still use them. The Media Library is basically just the UI front and starts with the default provider: localhost.
You can keep it that way and store everything locally or you can send your files to any provider like AWS s3, Rackspace, Cloudinary, or many others thanks to plug-ins developed by the community.
Search for "Strapi provider upload" on NPM and you’ll see all the available options.
There’s also the Awesome Strapi repo on GitHub that lists some of these providers.
4) Is it possible to generate the different sized images (small, medium, large) change file formats, e.g. from JPG to PNG with the original as a fallback?
Not right now.
This isn’t how the default setup works, but the idea is to be open to more extensibility in the future. So what you can do is build your own provider to implement whatever features you need or want.
Jim recently recorded a video that shows how easy it is to do. With 2 functions you can have an upload function and a delete function or anything else!
5) Is it possible to modify the sizes of images?
Not at the moment. We focused on the most commonly requested features, improving the base formats a bit along the way. However, like with changing file formats, you can always customize how it works to better match your use-case.
6) How do you choose the size (small, medium, large) of the image via the API?
At the moment the default behavior is to have all formats returned during the API call. You currently can’t select specific formats, but in the future we may provide filters to only receive URLs for the large image or other options.
7) Could GraphQL allow for choosing specific options?
Yes, GraphQL could help with that. You could ask for "formats large" and then receive the large ones.
The thing is though, right now it's just a JSON object and JSON objects have to get it all at once. We want to be able to customize the name of the formats in the future and creating a static type in GraphQL would limit us to whatever we set (e.g. small, medium, large).
In order to then change that we would then need to do it dynamically at some point in the future and that makes more sense in GraphQL.
8) Is it possible to customize the UID field?
You can just type whatever you want in the slug field. Strapi will check to see if it already exists and provide other options if that’s the case.
The slug has to be unique so it works with you to make sure it’s something different every time.
9) Can you share anything you’re working on for the next releases?
A lot of people are probably going to be excited to hear that we're beginning development of a very big feature: admin permissions!
We’re also working on a draft and publish feature, which will be really cool.
They might not come out in the next small release, but keep your eyes out for the next big release.
10) Is it possible to generate API documentation through the API?
Not at the moment, but when you start up a Strapi instance the documentation plug-in generates documentation.
So we have a plug-in that generates a swagger interface. You can then access that and show show the API that it was successfully generated.
11) Will role based access control be free?
On the product board card there’s a nice explanation about the differences between the community and enterprise editions of Strapi, specifically what will be included in each version.
Now, the enterprise edition is still in private beta, but the plan is to limit the community edition to three roles (admin, author, and editor) while the enterprise edition will be unlimited.
12) When will multi-tenancy be available?
It’s on on the roadmap and. Generally speaking though it’s not something we’ll be focusing on in the short-term, but that could always change. Be sure to check out the product board for any updates!
13) Will the code for enterprise edition be open source?
The license for the enterprise edition will be proprietary as expected. The community edition of Strapi will still be under the MIT license, it’s just the enterprise edition that will have a very specific license.
However, the code will still be publicly available on GitHub for everyone to see and contribute.
Want to see what will be covered in future meetups? Check out the strapi-meetups GitHub repo. You can also suggest new topics if there's anything you want the team to talk about.
Don't forget, you can always watch the full demos and catch all the discussions from the Q&A session over on Youtube: What's new in the latest Strapi releases?
If you enjoyed the story, Tweet about it!