by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Activity
  • Feb 02 12:39
    HeReleased Piral v0.10.0
  • Feb 02 12:36
    Hello!
  • Feb 02 12:06
    Hello!
hari9.nalluri
@Hari9Nalluri_twitter
Hi @team, Could you please help on this, we are facing issue with routing, due to dynamic pilets loading into shell, currently we have setup like this, shell is has its own routing, upon shell route selection we are loading pilet dynamically with this code
5 replies
image.png
image.png
shell route is like this
this setup is creating new instance of piral in shell , with new BrowserRoute , due to this routes are getting isolated,
image.png
Could you please suggest us , how do i render dynamic pilet into same piral instance without creating new,
Steve Rhoades
@steverhoades
If I emit an event from a pilet for instance pilet.emit('needsAuthentication') should I be able to pick this event up in the Portal? I am trying to determine how to have a pilet inform the portal instance that a 401 was received by the server and that a Login should be shown.
17 replies
Okafor Emmanuel
@nondefyde
I have a question. Can a pilet act as an instance. something like a portal inside a portal. nested pilets. Am new to this. been reading up
6 replies
M4sterShake
@M4sterShake
I'm new to Piral, so hi everyone! I have a question about sharing components between Pilets. We are currently working on setting up a shared component library, but we don't particularly want to import those components in each Pilet because doing so would mean that each project may have different versions of the same component. I was thinking of a solution where we import the entire component library in the Piral instance and pass it down to all of the Pilets. Does this sound like madness to anyone?
15 replies
Damon Salvatore
@damon3465_gitlab
Hello I discovered Next.js and Gastby and I'm thinking about how I can use these two frameworks. I'm writing to get ideas. Is it possible to use in pilets or pirals?
2 replies
M4sterShake
@M4sterShake

Hi all, I'm trying to share a dependency from the piral instance to pilets but as soon as I add the following snippet to my package.json:

"pilets": {
    "externals": [
      "styled-components"
    ]
  },

I get the error below:

ERROR in ./node_modules/piral-core/lib/modules/dependencies.js
Module not found: Error: Can't resolve 'parcel-codegen-loader' in '/Users/M4sterShake/repos/homepageApp/packages/web-app'
 @ ./node_modules/piral-core/lib/modules/dependencies.js 7:27-64
 @ ./node_modules/piral-core/lib/modules/index.js
 @ ./node_modules/piral-core/lib/createInstance.js
 @ ./node_modules/piral-core/lib/index.js
 @ ./node_modules/piral/lib/index.js
 @ ./src/index.tsx
 @ multi ./src/public/manifest.json ./src/public/fonts/fonts.css ./src/index.tsx
🚨  [0074] The bundling process failed: Invalid input.

Does anyone have any idea what might be causing this? I've tried with a few different packages but I get the same issue with all of them.

If anyone has any idea what might be causing this it would be super appreciated.

13 replies
Florian Rappl
@FlorianRappl
Community Standup (4)
  • When? Monday 7th of September, 5pm CET (8am PST, 3pm UTC)
  • Where? http://meet.piral.io
  • Who? Piral team and everyone who is interested
  • What? (we are fully back after Summer vacation, roadmap updates)
  • If you have something to show or discuss, please let us know!
M4sterShake
@M4sterShake

Hi all, I have a question about debugging nested Pilets.

I have a Pilet just registers an extension and is rendered by other Pilets, never by the Piral instance directly. Because of this, when I run pilet debug for this Pilet I just see an empty page as the only thing in the debug feed is the Pilet that I'm debugging. Is there a way to add other pilets to the debug feed? I've found the chrome extension, which allows me to add Pilets manually, but I'd like to have this happen automatically whenever I run pilet debug for this pilet if possible.

Does anyone know if this is possible? I was sure I saw something about this in the docs somewhere, but I can't find it now for the life of me. Anyway, I'd be super appreciative if anyone knows anything about this.

8 replies
Clayton Poitevin
@clayton.poitevin_gitlab

hello! first of all thank you for making and maintaining piral! I have a few questions about piral with Blazor, can anyone help me to figure it out?

  • will piral-blazor work with Blazor Server instances? (i think it will not, because wasm and SignalR seems to have very different setup process, but idk)
  • since piral-blazor uses the component references directly and will not reference index.html from wwwroot or anything, how can I structure styles (css) so my pilet wont interfere on other pilets?
  • is there any known issues with piral-blazor + webpack? earlier today I was trying to build my develop emulator for creating a pilet for blazor wasm and I could not get it working... when I changed to parcel, the build process started working! (I can give more details by opening a github issue but I'm checking first)

sorry if any of the questions seem noobish or out of place, but I'm a beginner on this microfrontend world!
thanks in advance!

7 replies
Mrityunjay Kumar
@mrityunjayk
I am using my piral app into pilet but getting below error. Which plugin to add?
Property 'createState' does not exist on type 'PiletApi'.ts(2339)
2 replies
Mrityunjay Kumar
@mrityunjayk
I am trying to start local pilet server but getting following error
command at piral app dir: npx sample-pilet-sevice
npm ERR! code E404
npm ERR! 404 Not Found - GET https://registry.npmjs.org/sample-pilet-sevice - Not found
7 replies
M4sterShake
@M4sterShake

Hi all, we've recently converted an app that was originally created using create-react-app into a Piral instance. We've now noticed that the bundle size is quite a bit larger and specifying --scope-hoist true when running piral build doesn't seem to have any effect. I've followed the scope-hoist parameter through, to find where its used, but it doesn't seem to be used by piral-cli-webpack in the build-piral action - https://github.com/smapiot/piral/blob/develop/src/tooling/piral-cli-webpack/src/webpack/run-build-piral.ts#L8.

I'm probably missing something though. Any pointers to getting tree shaking working would be great. Thanks :)

55 replies
Waqas Ali
@nicknaam
Hello guys, What is the difference between Pilet and a page ?
2 replies
Waqas Ali
@nicknaam
Hello guys, I have successfully integrated piral-core with an existing application. Added a pilet and it works. What would be the best approach to keep using the exiting components as it is. I don't want to convert those into pilets upfront. The idea is to run with a FAT app shell in the start and gradually convert existing pages/components to pilets.
8 replies
Florian Rappl
@FlorianRappl
Reminder: Community Standup (4)
  • When? Monday 7th of September, 5pm CET (8am PST, 3pm UTC)
  • Where? http://meet.piral.io
  • Who? Piral team and everyone who is interested
  • What? (we are fully back after Summer vacation, roadmap updates)
  • If you have something to show or discuss, please let us know!
1 reply
Jan Eirik Forland
@janforland
@FlorianRappl : I'm trying to add a favicon.ico file in my index.html file, but the webpack bundler complains that currently no loaders are configured to process this file? How to I customize the webpack-config to allow me to add this file?
50 replies
Waqas Ali
@nicknaam
@FlorianRappl i am using piral core. Is there any examples online on how to introduce external repos as pilets (i can create and update pilets locally) ? I am thinking to implement this model where the other developers can integrate their code as micro front-end. Their code lives in another repository. What they will do is push to a feed service and then that feed service is pulled into the app-shell ? This whole scenario is not very clear to me. Do I have to just refer to a feed service and then i can access all the pilets ?
7 replies
Waqas Ali
@nicknaam
I am trying to run the feed service locally but getting this error. image.png
Waqas Ali
@nicknaam
When i try to run npm i sample-pilet-service, i get the following error "\node_modules\uuid' do not define a valid '.' target"
6 replies
M4sterShake
@M4sterShake
Hey all, so I'm using CRA to build my Piral instance and am trying to get it to generate a type definition (.d.ts) file as part of the build, so that pilets can use types exported by my Piral instance. Currently no .d.ts file is created though. Does anyone know what I can do to get it to create this file in the build output? I can see its created when using the Piral CLI to run the build.
31 replies
Waqas Ali
@nicknaam
Hello all, I have an existing app made with https://nx.dev/react I have successfully integrated piral-core into it. But now i wonder how can i deliver the app-shell to other developers. When i package it using the prial-build command it only adds index.html and some icons and images to the package. I wanted to create a package and deliver it via private npm feed. but right now am struggling with creating the package. Any suggestion will be appreciated.
7 replies
Waqas Ali
@nicknaam
Has anyone used piral-core into an existing app made with nx.dev/react ? I can't build this app with piral and npm pack command build it but then i can't run the app-shell when i start to create a pilet.
Waqas Ali
@nicknaam
@FlorianRappl I have just created an app shell and created an nmp package. After that i created a new pilet based on that nmp package. But now when i start the app via pilet debug. The app start but I only see a blank screen. Looks like i have to do additional stuff to make the app work, not sure what. usually my app works on port 5000 but now when i start localhost:1234 something loads up but its blank.
8 replies
Waqas Ali
@nicknaam
Is there a way to change piral running port ? from 1234 to xxxx
2 replies
Florian Rappl
@FlorianRappl
Reminder: Community Standup (5)
  • When? Monday 14th of September, 5pm CET (8am PST, 3pm UTC)
  • Where? http://meet.piral.io
  • Who? Piral team and everyone who is interested
  • What? (Piral Feed Service enhancements, converters in pilets, piral-native)
  • If you have something to show or discuss, please let us know!
1 reply
M4sterShake
@M4sterShake

Hi all, I'm trying to get an idea of how environment variables work with pilets. E.g. my pilet makes a request to a server and the URL for that server is different in prelive to live. Whats the best way of changing this value between the two environments. I have a live feed and a prelive feed, so was wondering if the best way would be to publish custom data with my pilet to each of the feeds? If so, how do I get hold of that data within the pilet?

Thanks for any advice you're able to give

13 replies
Waqas Ali
@nicknaam
Hello guys. I am running piral core on my existing app and the app runs successfully. But the images and svg icons are not being loaded. The same path no more works and if i try to access the icons in the URL i can see the icon. All places that have icons are showing as broken. Is there a special way to show icons in piral ? maybe i missed something in configuration.
14 replies
Waqas Ali
@nicknaam
@FlorianRappl Two questions: 1) Any ideas no how to run backend apis when developing a Pilet ? I have some .netCore based APIs running in the backend.
4 replies
Waqas Ali
@nicknaam
Hi @FlorianRappl, A question about using Paths in ts-config. When i use path in ts config and refer it in my component then piral cli throw and error says "it can't recognize this ........" When i remove the path and use relative path it works. Any ideas ?
8 replies
Waqas Ali
@nicknaam
@FlorianRappl Question: I have just published a piral to feed service and served it from the feed service in my application. Which is awesome. one thing i notice is that i didn't get any css from the pilet. Althought, when i run pilet debug command i see my css styles applied. Do i have to install some library in the pilet so that is inlcudes .css in the build ?
2 replies
Rahul Pandey
@rahulpandey8920

Hello. I have started to look into running the sample-pilet-service behind HTTPS via nginx. I am getting the following error:
√ Pilet built successfully!
[0000] Using feed service "https://feed.piral.local/api/v1/pilet".
× [0065] Failed to upload via HTTP: self signed certificate in certificate chain.
‼ [0062] Could not upload "sample-pilet-1.0.0.tgz" to feed service.
× [0064] Failed to upload some pilet(s)!

Could someone please help me understand where I need to setup the root certificate ?

4 replies
Thomas Sanderson
@sattaman
Hi , I'm trying to get typings pulled across from a plugin , I am defining them in the plugin, but when exporting them , it isn't coping across the referenced types, and so although I can see the name of the type in the pilets node_modules, since the type itself isn't pulled it resolves to any. Is there any further config needed to make it embed the referenced typescript types?
Thomas Sanderson
@sattaman
nvm spotted a similar question further up and realised it was because the import was absolute, changing it to relative has fixed :)
Clayton Poitevin
@clayton.poitevin_gitlab

Hello again peeps! @FlorianRappl after analyzing piral-blazor I decided to try migrate my company's current project (which is written in Blazor Server) to piral-blazor! the project will be called "Project Yggdrasil". On my tests I'm running piral and piral-blazor "0.12.1".
Right now I'm trying to set the pilet to get all dotnet dependencies and calling the page on the Piral Instance... BUT unfortunately i'm having the following error on console:

Microsoft.JSInterop.js:162 Uncaught (in promise) Error: System.Reflection.ReflectionTypeLoadException: Exception of type 'System.Reflection.ReflectionTypeLoadException' was thrown.
Could not load file or assembly 'netstandard, Version=2.0.0.0, Culture=neutral, PublicKeyToken=cc7b13ffcd2ddd51' or one of its dependencies.

I tried to include netstandard.dll on reference.codegen but the error persists.

any help/thoughts would be appreciated! thanks in advance.

10 replies
Clayton Poitevin
@clayton.poitevin_gitlab
also @FlorianRappl , I would like to add suport to Piral.Blazor.Core for async dependency injection through declaring a "ConfigureServicesAsync" method on Module.cs and updating Blazor to last version... what is your opinion about it?
3 replies
Waqas Ali
@nicknaam
Hello guys, I have installed piral-core on my existing app. Now when i serve pilets from a feed The css is not loaded. Every thing works but only css is not being loaded. Anyone else faced similar issue?
Mrityunjay Kumar
@mrityunjayk
image.png

I am trying to use images under src->img folder from src->components but image is not loading

<Image className="img-fluid" src="{require('../img/404.png')}" alt="404" />
<img src="../img/404.png')}" alt="404" />

5 replies
M4sterShake
@M4sterShake

Hi all, I'm trying to work out how to upgrade libraries declared as external in the app shell that have breaking changes. So for example, if I want to upgrade the version of React (which is external and used by all my pilets) in my app shell and there's a fundamentally breaking change that would require changes in all my pilets in order avoid errors. How would I go about upgrading React in my app shell while keeping all of my pilets working?

I would rather not have to upgrade all my pilets immediately as this would require coordination of a lot of teams. It would also lead to some amount of downtime as I would upgrade the library in my app shell and release it and then all my pilets would be broken until I publish new versions of those.

Is there a way of sharing two versions of the same library from the app shell so that pilets could use either the old version or the new one? If that were the case I could upgrade the shared library to the latest, leaving the old one available. Then upgrade all the pilets over time and when they're all upgraded I could remove the old version of the library from my app shell.

Sorry for the long question and thanks a lot for any help you're able to give.

4 replies
Mrityunjay Kumar
@mrityunjayk
I am trying to do piral build but getting following message
Bundle emulator ...
  • Installing piral-cli-webpack ...'npm.cmd' is not recognized as an internal or external command,
    operable program or batch file.
4 replies
Thomas Sanderson
@sattaman
I am using dashboard-piral , but need to be able to specify the order of elements . Would the best way be to copy the implementation here https://github.com/smapiot/piral/blob/develop/src/plugins/piral-dashboard/src/Dashboard.tsx and add a sort within our app?
3 replies
Florian Rappl
@FlorianRappl
Reminder: Community Standup (6)
  • When? Monday 21st of September, 5pm CET (8am PST, 3pm UTC)
  • Where? http://meet.piral.io
  • Who? Piral team and everyone who is interested
  • What? (Bundle pilet, piral-debug-utils)
  • If you have something to show or discuss, please let us know!
Waqas Ali
@nicknaam
@FlorianRappl I have created a Demo repo where you can reproduce that in "piral-core" you are not able to load .css for pilets. https://github.com/waqasali47/piral-core-demo . You are run the pilet and you will see the stylesheet loaded but when you publish it and then run the app shell via piral debug, you don't see the style sheet.
35 replies
Waqas Ali
@nicknaam
image.png