I'm making a project on dialogflow / actions on google that has multi functionality outside of just transactions of physical products. I'm currently following the tutorial provided by google (I'll post the link below).
I'm just wondering if this is possible to deploy to the inline editor and it will work the same? Only reason I am asking is because in the tutorial they are using the firebase CLI and using a url for a webhook (Which I've seen them use in other tutorials, but I have always just used the inline editor and it's worked fine).I have tried already deploying to the inline editor and I got an error, although that could have just been me doing something wrong.
Just curious if anyone has done a similar project using the inline editor and it's worked?
Thanks for the help!
Github link here
Actions on Google link here
I would try to answer your questions below:
If this is possible to deploy to the inline editor and it will work
the same?
Yes. It would work the same in the Inline Editor ( because it is powered by Cloud Functions for Firebase ) as long as you handle
responses for all the intents required for your transactions.
But I would like to emphasize on following limitations using the Inline Editor for fulfillment:
The inline editor only supports two files: index.js and package.json (modifying package.json will install any dependencies you
specify upon deployment). Hence, It becomes difficult to keep the code
modularized using the inline editor.
You cannot save or download code modified in the inline editor without first deploying. Hence, It becomes difficult to debug your
intents before deploying.
So, I would recommend using the Webhook Fulfillment i.e setting up your local development environment and then using Firebase CLI to deploy your code to Firebase Functions.
I would recommend completing this codelab and then following the instructions in the Github link and Actions on Google links you mentioned in the question to complete setting up transactions in Actions on Google.
Good Luck!
Hope that helps!
Just an FYI for anyone wanting to use the inline editor on dialogflow, as the above answer stated, you can use the inline editor and it works fine. Just make sure you don't test it on the simulator on the actions on google console or else it won't work. Make sure it's on a smart speaker or a phone.
Related
I have seen a lot of docs websites that have the same layout or same features.
so I am wondering if there is a library used by all these docs.
how do they do this?
./docs -> files.md -> ./docs/files.html
like you see there are a lot of files with .md (sometimes also .mdx)
and they have the same functionalities (see below)
so I am wondering if they use the same js library to generate it?
I tried to search in all the repo, what they are using to generate, but nothing says the name of a library?
is there an npm package or CDN link to that js library?
that can get the .md files inside .docs, and based on the folder structure, create a list on the left with all topics, 2 buttons with next and previous, a button with edit this page on GitHub, etc...
if isn't possible I will do it by scratch, but writing HTML for every doc is time-consuming.
I prefer some markdown fast, build consistent docs, and automatically added to the first-page list on the left.
also the routing thing for getting previous and next elements I need to do it manually and this can be time-consuming.
is there something that does that for me, some web API that gets files .md if I need to do it from scratch?
but still prefering npm package if there is.
Example:
previous and next docs.
react native
deno
lusift
and they have a button with the text EDIT THIS ON GITHUB
Mozilla docs MDN
when scrolling, it will change the color of the currently viewed section
sketch API
but I never find the name of the library.
other functionalities are...
multi-page
and much more...
(I tried to search on Github, but never find it)
it's there a good docs generator for a programming library that I create?
I also google it: https://www.google.com/search?q=javascript+library+documentation
but nothing. the libraries there are for API GET/POST swagger etc...
but I am wanting a library for functions like if you write this function this happen, maybe also code snippet functionality to see what result give you that function.
something similar to StackOverflow. text to HTML (but not need any server-side things comlicated... just keep it simple the files are inside .docs in GitHub, so just simple stuff.
maybe I am writing wrong the google keyterm
I found the solution to this, by using the #evolutionxbox comment.
how to find?
if you want to find what library is used in a GitHub repo,
go to the package.json, there you can find the list of libraries that is used on the project
the name?
in this case, the library used is DOCUSAURUS
link: https://docusaurus.io/
is very simple to config and solves the job!
and is used by
Facebook,
and other big companies like:
supabase
redux
etc...
I am a relative beginner to working in Apostrophe. I'd like to start off by saying its a pretty great ecosystem and I've enjoyed the experience so far. However, I've run into an issue thats a bit confusing.
I've been using it to build a site for a client and I've run into a very odd issue. I have installed an instagram widget that I found via npm (https://www.npmjs.com/package/#kwsites/cms-instagram-widgets) and used it on my local host with relatively no issues, it worked and I moved on with my life.
However now I'm trying to deploy the site and the Instagram widget is not showing up in the browser when viewing on the server. Again the widget shows up perfectly fine in the browser when viewing off my local host which would indicate it did not install correctly on the server but after following all of the post install steps on the linked npm package, I am completely unsure of what to try next.
I have confirmed that the #kwsites package folder is in public/modules/ directory
Any help/tips from any of the Apostrophe experts out there would be appreciated.
I am using stagecoach for deployment (again, a great product) and mechanic to manage nginx. I don't know if any of this matters but the widget is making some API calls to Instagram, don't know if they would be affected by either of those tools.
EDIT: Inspection in safari yielded the following from my local host
And the following from my server
It just looks like the widget is not being generated and I cannot find any errors in the console. Note I can add and remove a widget, I just can't get any content to generate on the server (but can on local host).
So as noted in the comments, I believe the issue was due to instagram's legacy api requiring site authorization. However with Facebook pushing the new Instagam Basic Display API, the legacy is going to be killed at the end of this month anyway/apps will stop working. So I found this blog post and found it easily adaptable to an Apostrophe module. It requires signing up for Zapier but a basic account is free and its a really interesting tool. This solved my needs
I am doing a REST API tutorial where I use a JavaScript file to make AJAX calls to the API endpoints. I have pretty much everything built out but the JavaScript won't run and I think it's because PyCharm's Community Edition doesn't allow JS files. I am able to run CSS files.
This is not a new question, but I stumbled upon it while searching for similiar issue, a work around that can be used, in case NodeJS is installed on the machine, is to go to
Open 'Edit Run/Debug configuration' dialog
Edit Configurations...
Add New Configuration
Shell Script
Script text
and in the field Script text enter node FileName.js. Save the configuration and run it everytime you need to run the JavaScript file.
You are correct, PyCharm's Community Edition does not allow for you to run JavaScript.
You can learn more here but only the professional version allows JavaScript to run.
Good day all. I'm new to Grafana and we adopted it very recently at work.
I'm willing to create a plugin, I need to load a simple external js library and fire it in a Grafana panel, nothing extreme.
First problem: I don't want to use any building library (grunt or whatever), I just want to write the plugin javascript, I don't want to redistribute it. Where do I write the code?
Am I right to write the code I want to execute in the data/plugins/myplugin/dist/ folder? (I'm trying to follow the steps at Grafana Docs, but they are unclear as they talk about building and install scripts which I don't like to use).
Second Problem: Seems like that if I use the dist/ folder, the plugin get executed. Now, I'd like to import a external.js library into it, the external library will take care of display the data as I like.
into my myplugin_ctrl.js I write this:
System.register(['app/plugins/sdk', 'lodash', './css/clock-panel.css!','./libs/datamaps'], function (_export, _context) {
var PanelCtrl, _, _createClass, panelDefaults, ClockCtrl;
As you may notice, I've used the clock plugin that is used into the how-to at Grafana.
I'd like to import './libs/datamaps', what I managed to do is having this error upon adding the panel to a dashboard:
Plugin component error Error: Fetch error: 404 Not Found
Instantiating http://127.0.0.1:3000/data/plugins/test-panel/libs/datamaps
Loading http://127.0.0.1:3000/public/plugins/test-panel/clock_ctrl.js
What I'm doing wrong? Where do the datamap.js should be? Or how do I can import it into Grafana plugin?
I don't know if you really need to solve this with a plugin, as I couldn't find any mention about data retrieval from any data sources in your question. Also, I'm not yet very familiar with Grafana plugin development, but I was able to solve one JavaScript related problem without a need to write a plugin.
What I did: I put a Text element in html mode on a dashboard and inserted a <script>...</script> section as well as some HTML code. This worked until I updated Grafana to a newer version, where they started to block this due to security reasons. After configuring /etc/grafana/grafana.ini setting disable_sanitize_html = true in section [panels], I made it work again. You could do this, too, but keep in mind that this is a security risk, because the dashboards now allow to inject any kind of malicious JavaScript code.
See also this Grafana reference page for scripted dashboards.
I am having a really difficult time getting the cordova plugin authored by OAuth.io (https://github.com/oauth-io/oauth-phonegap) to work within the an ionic phone build. Everything is setup based off of the desktop version of the JS file they provide, wrapped in an Angular service for ease of unit testing, with another factory handling the actual flow of login/logout etc...
The issue I am running into is that now after switching to the plugin version and removing the referenced JS version, nothing works any longer. I can no longer pull up the facebook login page, nor have the global object 'OAuth' recognized outside of the injected service. The furthest I got in troubleshooting the issue is that the OAuth object is created, at least initially as I can log out the object, but anything after that does not appear to be recognized.
My web (working) version of code example is on plunker here: http://plnkr.co/edit/B4HdkkBKDP3Xv2riQGui?p=preview
Any thoughts on further troubleshooting or if there is another way of accomplishing this goal would be greatly appreciated!
We just published the version 0.2.0 of the OAuth.io Cordova/Phonegap SDK, which fixes the issue with Ionic.
Now you should be able to use the cordova plugin in a ionic app without any trouble, like this:
$ cordova plugin add https://github.com/oauth-io/oauth-phonegap
This version also contains features that were missing from the sdk, like the cache and the unified user info method.
You can get more information about all this on our github page:
https://github.com/oauth-io/oauth-phonegap
Hope this helps :)