Show source file of objects in Chrome developer tools - google-chrome-extension

When I use the React Developer Tools, I notice that it can show me the source code of the selected component. It's the button on the upper right corner of the Components panel.
When I click this button, it opens the source file in the Sources panel.
I'm writing a developer tool myself and I want to do something similar to this. How does the React Developer Tools do it? I didn't see any API in the documentation to do this sort of thing.

Thanks to #wOxxOm's comment, I was able to find the source code of this button. Turns out we just need to call chrome.devtools.inspectedWindow.eval('window.inspect(...)') passing the object that represents the component. Chrome/Edge will take care of find the source code and show it in the Sources panel.

Related

Gitlab: bookmark repo functionality - how and what?

Gitlab has little bookmark icons next to each repo (see screenshot below). However, clicking the icon (or anywhere in the row for that repo) takes you to the repo - the whole thing is a link, so clicking the icon doesn't bookmark the repo. I also can't find a way to bookmark a repo via its settings.
Furthermore, what does the bookmark functionality do? I was imagining that it pins it to the top of your list, or makes it available on a bookmarks page, both of which would be really useful for me ... but I'm not actually sure.
Weirdly enough, google really isn't helping me out with this one. Does anyone have some info about this functionality?
This is an example of a bit of a UX convention violation - you're right that icon is absolutely a bookmark and typically used for bookmarking something. However in this case it just signifies that row is a Project as opposed to a Group. If that icon is a bookmark, it's a Project. If that icon is a folder, it's a Group.
If you want to favorite Projects, you should star them by clicking on the Star icon in the upper right of the Project home screen, then when you click on "Projects" you can click on "Starred Projects" and see all your projects you've currently starred. You can also filter activity based on starred projects.

How to take screenshot of a whole webpage from browser in a single image

In lots of place i saw that people using long screenshot of a full webpage for presentation. I tried with snipping tool but i am not able to take screenshot of whole webpage in a single image. I want to know that how i can take long screenshot from browser like this
If you are using Google Chrome then this answer will be beneficial for you.
Just follow some simple step to take long screenshot of a webpage.
Step 1: Click the three dots, point to “More Tools,” then click on “Developer Tools.” Alternatively, you can press Ctrl+Shift+I on Windows or ⌘+Shift+I on Mac to open the Developer Tools pane.
Step 2: In the top right corner of the pane, click the three dots icon, then click “Run Command.” Alternatively, press Ctrl+Shift+P on Windows and ⌘+Shift+P on Mac.
Step 3: In the command line, type “Screenshot,” then click “Capture full-size screenshot” from the list of commands available.
The image should save automatically, but if you’re prompted to save the screenshot, select a destination on your computer, then click “Save.”
Note : This feature is ideal on websites with text-based content opposed to web apps, as it could potentially only capture the viewable screen.
For more descriptive answer go through this link
You can use this free Screen Capture tool at CtrlQ.org.
You just need to put the url of the page of which you want to take the screenshot.
For example, Here is a screenshot of your question
You can use Awesome screenshot. It's extension is also easily available for chrome. Just add it to chrome and you will have option to take screenshot as you want. Here is the link.
You can click on capture entire page option as here in the screenshot:

How to exclude some directories from "Analyze -> Inspect Code" in Android Studio?

One code directory is from a long working library, but the code inspector complains about many issues in it. How do I exclude it from analysis?
I've tried looking at the settings, and also tried right clicking on various things through the analysis.
I'd like the code inspection to work for most of my project, but not from parts of it that work and analysis is unneeded. In this case, it is a complex open source C language library where I do not want to touch the code.
Okay - I feel a bit dumb, but so others don't have to go through this, here are details. Also, it is very easy to screw this up - the Android Studio GUI will let you do stuff that looks good in the dialog, but doesn't work. It took me several tries to find the magic that works.
Here is the procedure:
From the main menu, select "Analyze" then "Inspect Code"
Click the button next to "Custom Scope"
Click the three dots button - to the right on the same line. A new dialog will pop up.
Click the plus ( + ) - upper left, to start a new Custom scope
Give it a name
Select "Local" or "Remote"
In the drop-down of the new dialog, select Project view
Of the four icons, click them until only the one for file display is emphasized
Find the top directory of what you want to analyze, and click "Include"
Find each directory you want to exclude, and click "Exclude" for each
Click OK - the custom scope dialog will close
Click OK - the analysis will run
In the future, that scope is available by name, but remember that it does not honor the implied scope if you right-click a directory in the hierarchy.

How can I delete a layer/item in Google Web Designer?

I have been working for a few days now making a simple web page to be a basic cv/bio. I started by making my headers for the page and some simple animations when switching window sizes. After playing with adding some different colors in, I noticed that an asset I added, wasn't transparent(as I had intended it to be).
That said, I have tried to delete the item from the assets Library to no avail. I've tried removing all relevant keyframes, as well as trying to delete it from the Master Rules. The program will not allow me to delete the item, except from the Library, which does not affect the item on the page whatsoever.
I may well be missing something completely obvious and shall feel a fool when this is answered. Thank you for your help in advance!
To delete a layer, click on it in the timeline so that it's highlighted and then press the Delete key on your keyboard.
If the element is an asset imported by you, for example a picture, you must select it at the library collapsible menu and click the trash. If you can't find this menu, clic on Menu > Window > Library.
On Responsive window, click Edit base document. You can now delete it.

How to create a Multi-tab webpage

I'd like to create a webpage with menus at the top, using Dreamweaver. So far the help info I have found online talks about using the "Spry" option from the "Insert" menu within Dreamweaver. But the version of Dreamweaver I have (latest downloaded from Adobe) does not have "Spry" when I go to "Insert". I found "Tabs" under "jQuery UI" under "Insert", and that looks great but when I tested it with IE, there was a pop-up "Internet Explorer restricted this webpage from running scripts or ActiveX controls" and the page looks all garbled up, unless I click "Allow blocked content". I cannot assume that end users will have the right setting on their IE to make this work and it may just look like the webpage is not well built.
Any advice on how I should proceed?
Thanks,
According to online help (https://helpx.adobe.com/dreamweaver/using/spry-widgets-general-instructions.html), Spry widgets are replaced with jQuery widgets in Dreamweaver CC and later. While you can still modify existing spry widgets on your page, you cannot add new spry widgets.
Regarding the problem of the page looking garbled up if scripts are turned off in the browser, I guess the only way around it is to code in such a way that the page degrades gracefully in browsers that don't support JavaScript.
I found a workable solution here:
http://www.elated.com/articles/javascript-tabs/

Resources