You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by "topratiksharma (via GitHub)" <gi...@apache.org> on 2023/01/22 16:46:45 UTC
[GitHub] [superset] topratiksharma opened a new issue, #22820: Dashboard not visible via embedded SDK.
topratiksharma opened a new issue, #22820:
URL: https://github.com/apache/superset/issues/22820
I am working to embed the dashboard inside my angular application using superset SDK.
After doing the whole integration the dashboard is not visible.
Used this below article to integrate the dashboard.
https://medium.com/@khushbu.adav/embedding-superset-dashboards-in-your-react-application-7f282e3dbd88
Below is my config changes apart from the default file.
```
FEATURE_FLAGS = {"ALERT_REPORTS": True,
"EMBEDDED_SUPERSET": True}
ALERT_REPORTS_NOTIFICATION_DRY_RUN = True
WEBDRIVER_BASEURL = "http://superset:8088/"
# The base URL for the email report hyperlinks.
WEBDRIVER_BASEURL_USER_FRIENDLY = WEBDRIVER_BASEURL
SESSION_COOKIE_SAMESITE = None
ENABLE_PROXY_FIX = True
PUBLIC_ROLE_LIKE_GAMMA = True
CORS_OPTIONS = {
'supports_credentials': True,
'allow_headers': ['*'],
'resources':['*'],
'origins': ['*']
}
GUEST_ROLE_NAME = "Admin"
GUEST_TOKEN_JWT_EXP_SECONDS: 300 # 5 minutes, or you could set it longer
```
I am using admin user as the default login and created custom as well as tried using the predefined dashboards.
User list

Dashboard settings

Chart Settings

My UI code.
```
```
#### How to reproduce the bug
### Expected results
Should see the dashboard on the application.
### Actual results
Blank screen with no errors.
#### Screenshot

### Environment
(please complete the following information):
- browser type and version: NA
- superset version: `superset version`
- python version: `python --version` NA
- node.js version: `node -v` : 16.15.0
- any feature flags active: Yes {"ALERT_REPORTS": True,
"EMBEDDED_SUPERSET": True}
### Checklist
Make sure to follow these steps before submitting your issue - thank you!
- [X] I have checked the superset logs for python stacktraces and included it here as text if there are any.
- [ X] I have reproduced the issue with at least the latest released version of superset.
- [ X] I have checked the issue tracker for the same issue and I haven't found one similar.
### Additional context
Add any other context about the problem here.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] topratiksharma closed issue #22820: Dashboard not visible via embedded SDK.
Posted by "topratiksharma (via GitHub)" <gi...@apache.org>.
topratiksharma closed issue #22820: Dashboard not visible via embedded SDK.
URL: https://github.com/apache/superset/issues/22820
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org
[GitHub] [superset] topratiksharma commented on issue #22820: Dashboard not visible via embedded SDK.
Posted by "topratiksharma (via GitHub)" <gi...@apache.org>.
topratiksharma commented on issue #22820:
URL: https://github.com/apache/superset/issues/22820#issuecomment-1399574120
Was supplying iFrame element instead of a div.
```
public embed() {
// const token = await this.fetchGuestTokenFromBackend();
const element = document.getElementById('my-dashboard');
embedDashboard({
id: '5a99f740-1f70-46f5-8563-422ec22badcb', // given by the Superset embedding UI
supersetDomain: 'http://localhost:8088',
mountPoint: element, // any html element that can contain an iframe
fetchGuestToken: () => this.fetchGuestTokenFromBackend(),
dashboardUiConfig: {
// dashboard UI config: hideTitle, hideTab, hideChartControls, filters.visible, filters.expa0nded (optional)
hideTitle: true,
// filters: { expanded: true },
},
});
}
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org