ROBOT |
ロボスタ |
東大発AIベンチャー「Deep Consulting」が設立 AI・ディープラーニングの導入支援を行い、AI活用とDXを促進 |
https://robotstart.info/2021/04/12/deep-consulting-established.html
|
deepconsulting |
2021-04-12 09:46:34 |
ROBOT |
ロボスタ |
Audibleの「アルクセットシリーズ」に「英語で味わう日本」「ビジネス英語 事始め」など全9テーマが追加 学習者のニーズの高まりに対応 |
https://robotstart.info/2021/04/12/audible_alc_setseries-add.html
|
audible |
2021-04-12 09:19:27 |
IT |
ITmedia 総合記事一覧 |
[ITmedia エンタープライズ] サポート切れCisco Small Businessルーターに緊急の脆弱性、アップデートの提供予定はなし |
https://www.itmedia.co.jp/enterprise/articles/2104/12/news125.html
|
ITmediaエンタープライズサポート切れCiscoSmallBusinessルーターに緊急の脆弱性、アップデートの提供予定はなし古いCiscoSmallBusinessルーターシリーズにリモートコード実行の脆弱性が存在するというセキュリティアドバイザリが発行された。 |
2021-04-12 18:30:00 |
IT |
ITmedia 総合記事一覧 |
[ITmedia News] LINEがリモート占いサービス コロナ禍で急増の“占い需要”に対応 |
https://www.itmedia.co.jp/news/articles/2104/12/news133.html
|
itmedianewsline |
2021-04-12 18:26:00 |
IT |
ITmedia 総合記事一覧 |
[ITmedia Mobile] ドコモの5G必須特許保有数は世界3位、5G規格の標準化活動をけん引 |
https://www.itmedia.co.jp/mobile/articles/2104/12/news127.html
|
itmediamobile |
2021-04-12 18:06:00 |
python |
Pythonタグが付けられた新着投稿 - Qiita |
FastAPI/SQLAlchemy初心者が1日で理解したこと(1週間だけ頑張る Day3of9) |
https://qiita.com/tagawa0525/items/8fe2245fc85cdc7979dc
|
前日の記事Dockerの学習ではPostgreSQLのデータの永続化はできていないが、とりあえず先に進む。 |
2021-04-12 18:44:45 |
python |
Pythonタグが付けられた新着投稿 - Qiita |
アノテーションツールELANのデータをpythonからテキストデータにエクスポート |
https://qiita.com/fmfm_mdk/items/572672205d4c6033c5a8
|
|
2021-04-12 18:38:46 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
Linuxのバックアップの仕方 |
https://teratail.com/questions/332843?rss=all
|
centos |
2021-04-12 18:59:42 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
サーバダウンの調査方法 |
https://teratail.com/questions/332842?rss=all
|
|
2021-04-12 18:54:57 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
docker,docker-composeを使ってcronを実行することができない |
https://teratail.com/questions/332841?rss=all
|
dockerdockercomposeを使ってcronを実行することができない前提・実現したいことDockerDockercomposeでpythonを使ったWebスクレイピング環境を作り、それをcronで自動実行させたいと思っています。 |
2021-04-12 18:50:04 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
[Laravel]authのlogin画面にCSSが効いていない原因がわかりません。。 |
https://teratail.com/questions/332840?rss=all
|
前提・実現したいことLaravelでログイン認証を実装しようと思ったのですが、以下のようなCSSが効いていない表示になっています。 |
2021-04-12 18:47:46 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
GASのメール送信でBCCを追加したい |
https://teratail.com/questions/332839?rss=all
|
GASのメール送信でBCCを追加したいスプレッドシートよりメール送信を各社にお送りしたいと思っております。 |
2021-04-12 18:41:30 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
「更新に失敗しました。 返答が正しい JSON レスポンスではありません。」と表示され、保存が出来ません。 |
https://teratail.com/questions/332838?rss=all
|
発生している問題・エラーメッセージ「更新に失敗しました。 |
2021-04-12 18:39:53 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
数理最適化の勉強方法について |
https://teratail.com/questions/332837?rss=all
|
数理最適化の勉強方法について今年大学院に進学し、これから数理最適化の研究をすることになりました。 |
2021-04-12 18:37:16 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
bootstrap4でtab-paneがactiveにならない |
https://teratail.com/questions/332836?rss=all
|
bootstrapでtabpaneがactiveにならない前提・実現したいことbootstrapでtabpaneがactiveにならない発生している問題keywordcomタブを新規に追加するとします。 |
2021-04-12 18:32:11 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
input要素のname属性を取得したい |
https://teratail.com/questions/332835?rss=all
|
input要素のname属性を取得したい前提・実現したいことjqueryでinput要素のname属性を取得したいです。 |
2021-04-12 18:31:01 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
javascriptでhtmlのタグ<table id="list-xxx">の"xxx"の部分を変数にして書き出していきたいのですが、良い方法はないでしょうか? |
https://teratail.com/questions/332834?rss=all
|
javascriptでhtmlのタグlttableidquotlistxxxquotgtのquotxxxquotの部分を変数にして書き出していきたいのですが、良い方法はないでしょうかjavascriptでhtmlのタグlttablenbspidquotlistxxxquotgtのquotxxxquotの部分を変数にして書き出していきたいのですが、良い方法はないでしょうかnbsp※ループでhtmlを書き出すのでjavascriptは複数回呼ばれます。 |
2021-04-12 18:22:37 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
バッチファイルでフォルダ監視 |
https://teratail.com/questions/332833?rss=all
|
バッチファイルでフォルダ監視バッチファイルを使ってフォルダを監視し、ファイルを別のフォルダに移動させたいと思っています。 |
2021-04-12 18:20:44 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
ハッシュ探索法 コードレビューお願いします! |
https://teratail.com/questions/332832?rss=all
|
ハッシュ探索法コードレビューお願いしますアルゴリズムの勉強をしています。 |
2021-04-12 18:19:57 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
アフィタグ 設置変数とはどこの箇所でしょうか? |
https://teratail.com/questions/332831?rss=all
|
bspnbspserialnbspnumbers |
2021-04-12 18:18:56 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
ファイルを読み込んで、各列の総和と平均を求めたい。 |
https://teratail.com/questions/332830?rss=all
|
ファイルを読み込んで、各列の総和と平均を求めたい。 |
2021-04-12 18:15:56 |
Program |
[全てのタグ]の新着質問一覧|teratail(テラテイル) |
AWS S3 アップロードしたファイルのオブジェクトURLを取得したい。 |
https://teratail.com/questions/332829?rss=all
|
AWSSアップロードしたファイルのオブジェクトURLを取得したい。 |
2021-04-12 18:08:57 |
Ruby |
Rubyタグが付けられた新着投稿 - Qiita |
HerokuからAWSに移行後のActionCableの設定方法 |
https://qiita.com/oogi_kojiro/items/6e8f8e826e797d5cd7de
|
HerokuからAWSに移行後のActionCableの設定方法概要本日、本番環境をHerokuからAWSに移行後、ブラウザ上で動作を確認したら、コメント機能の非同期通信で実装した所がうまく動作をしなかったので解決策をシェアしたいと思います。 |
2021-04-12 18:22:49 |
AWS |
AWSタグが付けられた新着投稿 - Qiita |
HerokuからAWSに移行後のActionCableの設定方法 |
https://qiita.com/oogi_kojiro/items/6e8f8e826e797d5cd7de
|
HerokuからAWSに移行後のActionCableの設定方法概要本日、本番環境をHerokuからAWSに移行後、ブラウザ上で動作を確認したら、コメント機能の非同期通信で実装した所がうまく動作をしなかったので解決策をシェアしたいと思います。 |
2021-04-12 18:22:49 |
Azure |
Azureタグが付けられた新着投稿 - Qiita |
Microsoft Build の OpenJDK をプレビュー版として提供開始 |
https://qiita.com/yoshioterada/items/38cc9e5e0c95f8be84e1
|
そして我々はJavaを利用するお客様と開発者の皆様のために、Javaサポートの拡大を継続的に取り組んでいます。 |
2021-04-12 18:16:41 |
Ruby |
Railsタグが付けられた新着投稿 - Qiita |
HerokuからAWSに移行後のActionCableの設定方法 |
https://qiita.com/oogi_kojiro/items/6e8f8e826e797d5cd7de
|
HerokuからAWSに移行後のActionCableの設定方法概要本日、本番環境をHerokuからAWSに移行後、ブラウザ上で動作を確認したら、コメント機能の非同期通信で実装した所がうまく動作をしなかったので解決策をシェアしたいと思います。 |
2021-04-12 18:22:49 |
海外TECH |
DEV Community |
Building a CSS-in-JS library from scratch |
https://dev.to/thomascullen/building-a-css-in-js-library-from-scratch-3id5
|
Building a CSS in JS library from scratchCSS in JS libraries are popping up all over the place at the moment They are a really powerful way to style apps but how do they actually work In this post we are going to build our own CSS in JS library Before we dig in it is worth saying that if you are looking for a CSS in JS solution you should probably use one of the existing libraries out there rather then building your own as they are well tested with more functionality Let s dive in We are going to create a simple css in js library that follows the styled API made popular by styled components We will only focus on basic functionality so we won t be looking at things like server side rendering or browser prefixing Most CSS in JS libraries work by taking style definitions generating class names for them and injecting them inside of a style tag in the document head So let s start by creating this style tag const style document createElement style document head appendChild style We can now attach any CSS rules we want to this style tag using the CSSStyleSheet insertRule method We can also make use of the cssRules method to ensure we are always adding the rule to the end of the list by providing the list length as the index we want to insert the rule at style sheet insertRule red color red style sheet cssRules length You can read more about the CSSStyleSheet interface here Next thing we need is a function that will take a CSS rule generate a className insert a new rule into our style tag and return the generated class name for us to use in our components For our use case we can simply use the index to create a unique class name instead of doing any kind of hashing like most libraries do function css styles const index style sheet cssRules length const className css index const rule className styles style sheet insertRule rule index return className Now we can use our css function to generate class names that we can provide to our components function Example const className css color red return lt div className className gt This is an example lt div gt That s great and all but it s far from the API that we want to have We want to be able to define components using the popular styled API like this const Example styled div color red In order to achieve this we need to take a quick detour to explore tagged template literals First we need to know what a template literal is A template literal is a type of string that allows you to interpolate values inside of them const color red const rule color color A tagged template literal is a special way of parsing a template literal with a function This function will be called with an array of all of the string parts as well as any variables provided function greet strings args console log strings strings console log args args const name Thomas greet My name is name strings My name is args Thomas Now that we know a template literal can be tagged with a function we can revisit out css in js implementation to achieve the API we want We need to create a styled function that takes the type of dom element we want to render and returns a function that we can then use as a tagged template literal to create our react component Let s keep things simple to start with and just take the styles that we pass in as is so that we can focus on getting the API we want function styled tag return function styledTemplate rules return function Component props remember that tagged template literals give us the string parts as an array so for now we just pass the first element of the array which will be the entire CSS rule because we aren t passing any variables const className css rules return React createElement tag className props I know that s a lot of functions returning functions Let s walk through it The styled function returns the styledTemplate function The styledTemplate function is similar to our greet function from earlier We call it as a tagged template literal This then returns the react component which we can render So with all of this in place we can do do the following const Header styled h font size px font weight lt Header gt This is a header lt Header gt So this is finally starting to look like the styled components API we wanted But what about things like adapting styles based on component props Let s say we wanted our Header component to change color based on a color prop as well as allowing the background color to be customized with a bg prop For that we need to revisit how we are treating the tagged template literal Remember how our greet function was given a second array of all of the variables passed into the template literal Well we can also pass functions into the template literal which we can then call will our component props at render time Let s create a new function that will process the string literal parts and any functions we provide it into a single CSS rule function resolveRule parts args props return parts reduce output part index gt if index rules length return output part return output part args index props With this function we only have one thing left to do which is to update our styled function to make use of it function styled tag return function styledTemplate rules args return function Component props const resolved resolveRule rules args props const className css resolved return React createElement tag className props And there we have it Our very own CSS in JS library const Header styled h font size px font weight color props gt props color black background color props gt props bg transparent Further Reading tkh writing a css in js library from scratch cdab |
2021-04-12 09:28:25 |
海外TECH |
DEV Community |
What is API testing? Advantages of API testing |
https://dev.to/qablehq/what-is-api-testing-advantages-of-api-testing-p94
|
What is API testing Advantages of API testingBefore going for API testing let s have a quick look at the brief introduction of API What is API Basically API is a connecting source that enables the exchange of information between two different applications In more simplified term the function of API is to deliver the user s response to the application and send application s response to the user Furthermore API is a collection of functions that enables applications to interact with the microservices operating systems and other components of an existing software You can check out this example We all are quite used to making online payments through various modes like Internet Banking UPI Wallets etc This is an application of Payment Gateway API Here you will get to know about the concepts of API testing services processes and benefits of API testing What is API Testing To validate the performance reliability and security of the Application Programming Interface API the QA team follows the API testing method Also the main objective of API testing is to verify the responsiveness and functional behavior of the API under various scenarios During API testing testers prefer to use software to send calls to the APIs and validates their performance Also they make a note of the system s response Moreover during the process the team keeps all the attention on the business logic layer rather than the look amp feel etc Furthermore to deliver accurate outputs you must examine the APIs and hence knowing about the API testing process is a must Why does API Testing need to perform If you are thinking about the need for API testing the following section will help you We are living in a time where users expect everything ready This is the reason IT companies are inclining towards the concept of microservices Moreover microservices facilitate different datastores corresponding to each section of the application that requires different commands for operations Companies prefer to use the concept of microservices because it allows quick deployment which further makes the development process smoother However we have shared the concept of microservices because APIs play an important role here Each section of the applications gets commands through the API only Now you must be able to connect microservices and APIs Hence API testing is a must to do because it helps to identify the errors or bugs at the very early stage of development Also through API testing we get to know whether the API is effectively interacting with all the sections of the code or not Here testers validate the response of the API Furthermore you must have heard “Sooner is better and the same goes here Finding bugs at the earlier stages always make the application more productive and robust Also it protects the application from further damages Because of these important reasons one should definitely go for the API testing process Also the mobile API testing is equally significant Do you know about API Testing in the test pyramid If you are investing more than expected time waiting on the test suite to run Also if there is a scenario in which you are rerunning the test suits because it fails every time If you are experiencing these kinds of issues you are missing the test pyramid Basically the test pyramid is a framework that helps developers to bring quality to the product It acts as a guide to make an application robust and fast which further drives them towards the reliable test suite Being a leading API testing company we always recommend including the test pyramid because it offers immediate feedback to the development team that the updated code will not damage the existing features of the application As a result the developer takes the decision either to move ahead with the code or not which further helps in saving time and building the robust platform Levels of Pyramid TestingMoreover the test pyramid consists of three levels The pyramid name is given because of this structural flow Lowest level Unit testing Middle tier Integration testing Top level End to end testing Also the implementation of the test pyramid reduces your waiting time that you spend for a test suite to run Advantages of API testing services So far you know about API testing and the reasons why we use it Now here we will get to know about some concrete advantages of the running API testing process Saves Time Do you think we need to explain the worth of time In such a competitive time if you are not smartly optimizing your time you will be lagging Through API testing services testers save time because API testing always takes lesser time as compared to GUI functional testing For instance If we compare both the concepts practically we find the worth of API testing Suppose you are running automated API tests it will take only hours whereas if you perform the same activity for GUI tests it will take hours approximately Big difference guys we can do lots of productive tasks such as marketing in the saved hours Moreover when API testing is saving time will automatically save your cost Hence acknowledge API testing benefits and plan the execution accordingly No dependency on programming language During API testing the exchange of data takes place using XML or JASON So in order to perform the activity the testing team is free to select any core language Also it does not demand too much technical knowledge If you know how to perform testing that is enough Earlier identification of the bugs This is one of the main API testing benefits because it increases the productivity of the application by saving cost and time both Also when the developer gets bugs at the initial stages they resolve them more efficiently Moreover as we know codes are always interrelated with each other and a small bug can be a bigger issue at the later stages Also resolving them becomes complex and takes time as well So these are the API testing benefits and one should always include API testing prior to delivering an application to the client Top Tools for the API Testing PostmanTesters who are not comfortable dealing with the code in an IDE using the developer s programming language should go for Postman It is the tool to perform API testing Basically Postman was only a Chrome browser plugin and by this it has extended its limits The tool offers their solution for Windows as well as Mac Advantages of PostmanNo need to learn the new programming language An interactive interface that makes it easy to understand Supports maximum OS operating systems like Windows Mac Linux etc Facilitates features of Run Test Monitor and Document Easy KT Knowledge Transfer process Rest AssuredFor those who are looking for API testing in Java language only Rest Assured will be a reliable option Also it is open source and one can efficiently work on it Moreover in order to use the API testing tool one should not be an HTTP expert Advantages of Rest AssuredThe tool is available with in built functions and you are not required to write code from scratch In order to test the Web APIs no expertise in HTTP is required Rest Assured supports BDD Behavior Driven Development testing Katalon Studio Katalon Studio facilitates end to end testing services and hence became the leading tool for API testing Also it offers solutions for programmers as well as testers Moreover the team prefers to use it because it is free and one can test even Desktop Apps Web Apps and Mobile Apps Actually Katalon Studio is an emerging API testing tool that supports SOAP and REST requests Advantages of Katalon Studio It supports CI DC Integration Katalon Studio is based on the data driven concept Supports SOAP as well as REST APIs Works well across multiple operating systems like Mac Windows and Linux Non technical person can also work on the tool comfortably SoapUI When you are finding yourself in the most complicated scenario during API testing simply for SOAP API It helps developers to execute tests for Web Services REST and SOAP APIs The tool is dedicatedly built for API testing that creates custom codes by the use of Groovy The tool becomes easier to access because of its drag and drop feature Advantages of SOAP API One can test the most complex scenario with the help of the tool Exclusively for API testing Supports asynchronous testing Easy to run test cases PAWAn API testing tool that is designed for MAC operating systems Whether you are an API user or a creator PAW will be useful for you anyway It helps to create HTTP requests Also with the help of PAW testers will be able to examine the response from the server Moreover it allows the QA team to generate the client codes as well These magnificent features make it the leading API testing tool for MAC Advantages of PAW Enrich with an interactive and attractive interface Very easy to learn and perform testing Gives concrete performance as compared to other API testing tools It holds the feature of multi dimensional settings JMeterBy seeing this name you must be thinking about load testing You are right Initially JMeter was created to perform load testing but because of its extra features people start using it for API testing as well Also it performed well and that is why still in trend The additional features of JMeter make API testing easier and result oriented Advantages of JMeterEnrich with features to test API as well as performance Reduces testing efforts Supports Jenkins so can be integrated with the CI pipelines Karate DSLWith powerful assertion capabilities here comes another API testing tool Karate DSL is an open source framework based on the cucumber library The API testing tool helps to create environments for API based BDD tests using simple methods Here no need to write long step by step definitions in order to execute the run Advantages of Karate DSLKarate DSL supports configuration switching For API testing it allows reusing of payload data The tool supports multi thread parallel execution Simple and easy to execute tests AssertibleIf you are looking for a reliable API testing tool Assertible can also be an option It follows CI Continuous Integration and delivery pipeline for automated API tests Also the testing tool supports GitHub Slack and Zapier Assertible has a Sync feature that allows testers to update their tests automatically if any change is made in their specification A new feature was introduced to Assertible in Oct which we call Encrypted Variable Here you get a new and secure way to store passwords tokens and data which further improves the performance of the APIs Advantages of AssertibleOffers validation of HTTP responses Keeps JSON Path integrity tests No manual intervention is needed towards any change in specification ROI for the API Testing We at QAble a leading API testing company across the globe and by using our experience we are highlighting the ROI of API testing By reading the above content you must have understood the worth of web API testing as well as mobile API testing Also we understand building a product and launching it in the market is not everyone s cup of tea and hence you need to be smart to make your product smart If you follow the right approach and strategies from development to execution you will get the best returns on your investment By following the API testing process you will be able toGenerate more time to market the product Gain client s trust easily Save time and save cost Make your application more productive Maximize the revenue ConclusionHence always give priority to API testing Also if you are looking for the most prominent API testing company QAble will be on the top Feel free to share your queries We will be more than happy to assist |
2021-04-12 09:28:20 |
海外TECH |
DEV Community |
Solution: Beautiful Arrangement II |
https://dev.to/seanpgallivan/solution-beautiful-arrangement-ii-1lag
|
Solution Beautiful Arrangement IIThis is part of a series of Leetcode solution explanations index If you liked this solution or found it useful please like this post and or upvote my solution post on Leetcode s forums Leetcode Problem Medium Beautiful Arrangement II Description Jump to Solution Idea Code JavaScript Python Java C Given two integers n and k you need to construct a list which contains n different positive integers ranging from to n and obeys the following requirement Suppose this list is a a a an then the list a a a a a a an an has exactly k distinct integers If there are multiple answers print any of them Examples Example Input n k Output Explanation The has three different positive integers ranging from to and the has exactly distinct integer Example Input n k Output Explanation The has three different positive integers ranging from to and the has exactly distinct integers and Constraints The n and k are in the range lt k lt n lt Idea Jump to Problem Description Code JavaScript Python Java C For this problem we have to think about the nature of the range of possible values for k and their matching arrays The smallest value of k possible is obviously which can be achieved by a strictly increasing or decreasing array Thinking about the largest possible value for k however is slightly more challenging First we can consider the range of values in our array which is n The largest possible absolute difference of any two numbers in that range would obviously be the difference between the two extremes and n which is n Since the smallest possible absolute difference is obviously then it would appear to perhaps be possible to achieve each difference in the range n or a k value of n But is this actually possible Let s take n and k for example The only possible way to get the absolute difference of would be for and to be consecutive After that there are two possibilites for next smallest absolute difference of which are amp or amp Since the and are already next to each other that means we can achieve this second step with either or or their reverses Continuing this trend along we can gradually see that we can indeed achieve the maximum k value of n by zig zagging back and forth between the remaining extremes as we add them to our array In the previous example one such example would be The question then remains how we go about achieving some medium value of k larger than but smaller than n The answer to that lies in considering the array to be made of two parts In the first part k we can achieve our k number of absolute differences then we can simply fill in the remaining range k n with the ideal incrementing values without increasing the value of k For example if we have n and k we would build the first part the same as the last example then we would add on the remaining values in increasing order to make the wole array To acheive the zig zag fill we can use variables for the top and bottom values of our first part a z then use a modulo operation i to alternate between the two options remembering to increment decrement the respective variables each time they re used Implementation The are only minor differences between each of the four languages Javascript Code Jump to Problem Description Solution Idea var constructArray function n k let ans new Array n for let i a z k i lt k i ans i i z a for let i k i lt n ans i i return ans Python Code Jump to Problem Description Solution Idea class Solution def constructArray self n int k int gt List int ans a z n k for i in range k if i ans i z z else ans i a a for i in range k n ans i i return ans Java Code Jump to Problem Description Solution Idea class Solution public int constructArray int n int k int ans new int n for int i a z k i lt k i ans i i z a for int i k i lt n ans i i return ans C Code Jump to Problem Description Solution Idea class Solution public vector lt int gt constructArray int n int k vector lt int gt ans n for int i a z k i lt k i ans i i z a for int i k i lt n i ans i i return ans |
2021-04-12 09:20:40 |
海外TECH |
DEV Community |
JavaScript Basics- Scopes & Hoisting |
https://dev.to/debarshi95/javascript-basics-scopes-hoisting-2lmj
|
JavaScript Basics Scopes amp HoistingIf you re a JS beginner you must be have heard with these words Let s get in depth to understand more about these concepts in JS What is a Scope in JS A scope in JS is a context in which values and expressions are visible or can be referenced In simple words Scope is the accessibility of variables functions and objects in some particular part of your code during runtime Types of scopes in JS JavaScript has types of scopes Global Scope Any variable function expression that is present globally or not declared inside any other function belongs to the global scope Variables functions that declared in global scope can accessed from anywhere in the program var foo declared in the global scopefunction greet console log foo greet Prints console log foo l Prints Local or Function Scope Variables and functions that are enclosed in some other function become part of that function s local or function Scope In other words a local scope or function scope is associated with a function when we declare variables and functions inside another function they become part of the local function scope and are restricted to that scope Variables and function declared in function local scope are accessible within that scope Declared in Global Scopevar foo function bar Function or Local Scope var message Hello JavaScript inside the local function scope of bar console log message Prints Hello JavaScript console log foo Prints Global Scopeconsole log message Uncaught ReferenceError message is not definedBlock Scope Variables declared with let and const can block scoped That is they can be enclosed within a pair of curly braces blocks Any variable function declared with let or const inside a pair of curly braces are only available within the scope of the braces It stands true for only for variables that declared with let and const and not with var Block scope let message Hello JavaScript declared with let var name Debarshi declared with var console log message Prints Hello JavaScript Global scopeconsole log name prints Debarshi console log message Uncaught ReferenceError message is not defined Hoisting in JS In JavaScript hoisting is a concept in which a function or a variable can be used before declaration The happens as the JavaScript compiler moves all the declarations of variables and functions at the top of the scope Hoisting with variables and functions declared with var keyword Variables declared with var keyword gets hoisted to the top of the scope If accessed before initialization they result undefined console log baz Prints undefined console log greet Prints undefinedgreet Prints TypeError greet is not a function var baz Hello World anonymous function stored in a variablevar greet function console log Hello JavaScript greet Prints Hello from JavaScript Hoisting with variables and functions declared assigned with let and const keywordAlthough variables and functions declared assigned to let and const are also hoisted but they cannot be accessed until they have been initialized console log a Prints ReferenceError Cannot access a before initialization console log name Prints ReferenceError Cannot access m before initialization doSomething Prints ReferenceError Cannot access m before initialization let a Initializedconst name Debarshi Initializedconst doSomething function console log Hello World console log a Prints console log name Prints Debarshi doSomething Prints Hello World Hoisting with functions Functions declared with function keyword Functions that are declared with the function keyword are also hoisted and can accessed from the top of the scope foo Prints Hello from foo function foo console log Hello from foo Anonymous functions functions expression As anonymous functions and function expressions are assigned stored to a variable they behave same as that of the variable depending on the variable type they are assigned to baz Uncaught ReferenceError Cannot access m before initialization foo TypeError m is not a function var baz function assigned to var console log Hello from Baz let foo gt assigned to let console log Hello from Foo baz Prints Hello from Baz foo Prints Hello from Foo Temporal Dead Zone in JS let and const variables cannot be read written until they have been fully initialized which happens when they are declared if no initial value is specified on declaration the variable is initialized with a value of undefined Accessing the variable before the initialization results in a ReferenceError TDZ starts at beginning of scope console log bar undefined console log foo ReferenceError var bar let foo End of TDZ for foo References MDN |
2021-04-12 09:04:57 |
海外TECH |
DEV Community |
How to create a Skip Navigation link |
https://dev.to/savvasstephnds/how-to-create-a-skip-navigation-link-5e56
|
How to create a Skip Navigation link AboutWhen navigating a website with a keyboard it s often that you ll have to tab through the website s navigation header before getting to the main content It gets especially frustrating when you get through loads of pages to get where you want In this tutorial I will walk you through creating a Skip Navigation link so that your keyboard users can easily avoid tabbing through the navigation and get straight to the main content What are we building What we are creating here is basically a link that is invisible while browsing the website but becomes visible once it gains focus when the user navigates the site with the Tab key Why Before we move on to the tutorial let s answer the common question Why do I need to make my site fully accessible with a keyboard Some users rely on the keyboard for navigating the web Users with motor disabilities often find it difficult to navigate with a mouse or any other device We therefore need to make sure that our website is accessible with a keyboard This article from WebAIM does a better job at explaining the importance of keyboard accessibility Setting up our websiteFirst things first let s create the basic layout of our website The end result will look something like this It ll be a basic home page with A lt header gt which contains lt nav gt which contains the navigation elements in a lt ul gt A lt main gt section which contains the main section of our website with some dummy lorem ipsum text HTML lt DOCTYPE html gt lt html lang en gt lt head gt lt meta charset UTF gt lt meta http equiv X UA Compatible content IE edge gt lt meta name viewport content width device width initial scale gt lt title gt Document lt title gt lt link rel stylesheet href style css gt lt head gt lt body gt lt header gt lt nav gt lt ul gt lt li gt lt a href id site name gt MySite lt a gt lt li gt lt li gt lt a href gt About lt a gt lt li gt lt li gt lt a href gt Projects lt a gt lt li gt lt li gt lt a href gt Contact lt a gt lt li gt lt ul gt lt nav gt lt header gt lt main gt lt article gt lt p gt lt a href gt Lorem ipsum dolor lt a gt sit amet consectetur adipisicing elit Explicabo aperiam distinctio nostrum cum incidunt pariatur consequuntur ullam Odit laboriosam magni amet eligendi perferendis corporis quae Obcaecati eaque iusto magnam mollitia porro tenetur temporibus ex magni vero inventore nulla hic ipsum nostrum repellendus ut reiciendis repellat Aliquam consequuntur in perferendis beatae lt p gt lt p gt At placeat natus nemo quam fuga ipsam accusantium in vitae nam quae velit numquam alias perspiciatis veniam quod eligendi aliquam fugiat ipsum doloremque laudantium Id eum nobis cupiditate laudantium est in soluta quasi accusantium rem quos unde iusto voluptates quibusdam dolore quaerat provident laboriosam ipsum natus nam perspiciatis possimus Laborum lt p gt lt p gt Minima pariatur accusamus sequi hic fuga consequatur eaque veritatis molestias vel atque fugiat natus nesciunt suscipit laborum non sunt quaerat cum ea assumenda deserunt voluptates vitae iusto sed ducimus Eligendi quos nam exercitationem et adipisci vero iure quidem ad Amet quia exercitationem illum soluta doloremque dolorum aperiam totam vel ipsum lt p gt lt p gt Animi beatae dolores laborum placeat sed corporis minus reprehenderit commodi officia eligendi magni expedita alias sunt saepe quas Mollitia cum rerum aperiam reprehenderit Aliquam tempora nemo mollitia sed tenetur eaque labore sit fugit illo consequuntur At quibusdam adipisci beatae a reprehenderit iure vitae maxime perspiciatis Necessitatibus aperiam ratione ad perspiciatis lt p gt lt p gt Repudiandae fugiat veniam sint quibusdam itaque earum expedita provident quasi dolor repellendus Maiores expedita Ut neque quo doloremque quaerat repellat corporis laudantium voluptatibus omnis a qui blanditiis dolorem odio quia voluptatem ullam nam harum necessitatibus cupiditate pariatur distinctio aliquam labore Beatae in reprehenderit sint Quae molestiae reiciendis voluptates dolor pariatur lt p gt lt p gt Voluptate enim minus omnis beatae quisquam perspiciatis ea atque eos quaerat ab vitae tenetur explicabo nisi tempora exercitationem amet ullam debitis earum dolore Unde ea quia aliquid similique delectus culpa molestias neque dignissimos corporis odit ab necessitatibus impedit deserunt dolore Rem blanditiis vel Doloribus minima alias facere iure nemo consequuntur lt p gt lt p gt Fugit laudantium reiciendis vero molestiae facere Voluptate maiores similique vitae ipsa nam ipsum saepe sit rem sapiente debitis nihil temporibus asperiores laborum velit odio inventore recusandae ratione Officiis laborum fuga nostrum quo cum repellendus soluta expedita iusto qui corporis aliquam perspiciatis minus accusantium in ut Voluptates quia omnis fuga ipsum lt p gt lt p gt Porro sint numquam placeat molestias soluta hic velit ratione commodi nam earum et a delectus molestiae praesentium officia eaque adipisci error aut asperiores Voluptates quos eveniet magni optio amet culpa dolorum ad quidem ipsam incidunt illum explicabo non atque rerum blanditiis labore harum dolore repudiandae quod repellat Quisquam nobis odit lt p gt lt p gt Eaque quos eveniet voluptas commodi assumenda nostrum id in veniam nulla tenetur itaque provident Ex numquam nesciunt quaerat est quos ab doloremque debitis harum facere quae Dicta non doloremque aperiam a nisi totam modi quis assumenda deserunt animi quaerat Ratione veritatis enim cupiditate ut et facere veniam quasi Tenetur autem lt p gt lt p gt Sit hic consequuntur Dicta adipisci nobis voluptatibus excepturi nemo veritatis iusto in vel magni laborum perspiciatis impedit Dolorum ducimus soluta consectetur neque voluptate totam architecto temporibus autem veritatis perferendis sit ratione officia illum quidem vel iste obcaecati eaque consequatur Autem quo repellendus nihil quisquam Doloremque repellendus natus magni illum tempora lt p gt lt article gt lt main gt lt footer gt Savvas Stephanides lt footer gt lt body gt lt html gt CSS margin padding font family Gill Sans Gill Sans MT Calibri Trebuchet MS sans serif body background color bea header background color box shadow px px e header nav width px margin auto header nav ul list style none display flex header nav ul li a color white display block padding px text decoration none header nav ul li a hover text decoration underline header nav ul li a site name font weight bold color white main article width px margin auto margin top px main article p padding px px line height main article p main article p a color white Create the Skip Navigation linkNow we need to create our link For this we need to do things Make our lt main gt tag an anchor so we can navigate to it easilyCreate a link which takes the user to the main sectionHide it with CSSUse CSS to make the link visible on focus Make our lt main gt tag an anchorTo do this all we need to do is give an ID to our lt main gt tag Let s call it main part lt main gt lt main id main part gt Create the linkNow we need to create our Skip navigation link right under our lt body gt tag and right before the lt header gt tag lt body gt lt a href main part id skip navigation gt Skip navigation lt a gt lt header gt Make it invisibleNow we need to hide it from the user We do that with CSS skip navigation position fixed top left background color color white text decoration none padding px border px solid e Notice the position fixed and top lines These are the lines that make the link invisible Make it visible on focusLastly we set the top parameter of the link when it has the focus skip navigation focus top And that s it As soon as you open the page and press the Tab button the Skip Navigation button should show up Pressing the Enter key should take you straight to the main content See live demo ConclusionHas this tutorial been helpful Let me know here or on Twitter |
2021-04-12 09:02:45 |
Apple |
AppleInsider - Frontpage News |
Mini LED production issues hit forthcoming iPad Pro, shortages expected |
https://appleinsider.com/articles/21/04/12/mini-led-production-issues-hit-forthcoming-ipad-pro-shortages-expected
|
Mini LED production issues hit forthcoming iPad Pro shortages expectedManufacturers are reportedly facing problems with producing mini LED displays in volume for the forthcoming inch iPad Pro Apple s inch iPad ProApple has been expected to release two new iPad Pro models as soon as April but there are now issues with the mini LED backlighting technology This new system expected to be exclusive to the inch iPad Pro at first improves the display by producer darker blacks and better contrast Read more |
2021-04-12 09:51:43 |
海外TECH |
Engadget |
Google is shutting down its iOS and Android Shopping apps |
https://www.engadget.com/google-closing-mobile-shopping-app-092538534.html
|
shopping |
2021-04-12 09:25:38 |
金融 |
金融庁ホームページ |
入札公告等を更新しました。 |
https://www.fsa.go.jp/choutatu/choutatu_j/nyusatu_menu.html
|
公告 |
2021-04-12 10:00:00 |
金融 |
金融庁ホームページ |
職員を募集しています。(金融商品市場制度等に関する企画及び立案に従事する職員(係長クラス)) |
https://www.fsa.go.jp/common/recruit/r3/kikaku-03.html
|
金融商品市場 |
2021-04-12 10:00:00 |
ニュース |
BBC News - Home |
Covid lockdown eases: 'Sense of celebration' as pubs and shops reopen |
https://www.bbc.co.uk/news/uk-56710858
|
england |
2021-04-12 09:32:43 |
ニュース |
BBC News - Home |
NHS Covid-19 app update blocked for breaking Apple and Google's rules |
https://www.bbc.co.uk/news/technology-56713017
|
users |
2021-04-12 09:28:01 |
ニュース |
BBC News - Home |
Joseph Siravo: The Sopranos and Jersey Boys star dies aged 64 |
https://www.bbc.co.uk/news/entertainment-arts-56716261
|
johnny |
2021-04-12 09:33:16 |
ニュース |
BBC News - Home |
What's the roadmap for lifting lockdown? |
https://www.bbc.co.uk/news/explainers-52530518
|
lockdown |
2021-04-12 09:12:13 |
ニュース |
BBC News - Home |
Covid: Restaurants and pubs have reopened, but what are the rules? |
https://www.bbc.co.uk/news/business-52977388
|
england |
2021-04-12 09:08:32 |
ニュース |
BBC News - Home |
Covid: When will I get the vaccine? |
https://www.bbc.co.uk/news/health-55045639
|
blood |
2021-04-12 09:03:03 |
ビジネス |
ダイヤモンド・オンライン - 新着記事 |
ヨンドシー(4℃)HD、11期連続の「増配」を発表し、 配当利回り4.36%に! 配当額は11年で4.1倍に増加、 2022年2月期は前期比2円増の「1株あたり83円」に - 配当【増配・減配】最新ニュース! |
https://diamond.jp/articles/-/268287
|
|
2021-04-12 18:05:00 |
GCP |
Google Cloud Platform Japan 公式ブログ |
Cloud Spanner のマルチリージョン構成について理解する |
https://cloud.google.com/blog/ja/topics/developers-practitioners/demystifying-cloud-spanner-multi-region-configurations/
|
まとめ強力な読み込みステイル読み取りリージョン間の読み取りのレイテンシが大きい低レイテンシ確実に最新データを提供読み取りデータが最新でない可能性あり書き込みを読み取る必要があるアプリケーションには必須最新でないデータを許容でき、レイテンシの影響を受けやすいアプリケーションに最適終わりにCloudSpannerは強整合性と高可用性を両立しているだけでなく、インスタンス構成、レプリカの種類、読み取りの種類強力な読み取りとステイル読み取りに選択の幅があり、アプリケーションのレイテンシや障害に対する復元力の要件に応じた使用が可能です。 |
2021-04-12 11:00:00 |
GCP |
Google Cloud Platform Japan 公式ブログ |
FFN がクラウド上のフルマネージド データベースへの移行を加速した方法 |
https://cloud.google.com/blog/ja/products/databases/migrating-financial-data-to-cloud-with-database-migration-service/
|
オンプレミスインフラストラクチャからの開始Googleのデータクラウドに移行する前、当社のシステムはRackspaceでホストされていて、そのアーキテクチャはつのビジネスユニットに分割されていました。 |
2021-04-12 10:00:00 |
北海道 |
北海道新聞 |
後発薬の小林化工が補助金返還 5・6億円、水虫薬の違法製造で |
https://www.hokkaido-np.co.jp/article/532266/
|
睡眠導入剤 |
2021-04-12 18:13:00 |
北海道 |
北海道新聞 |
ノーベル賞の吉野さん終身教授に 名城大、功績たたえ |
https://www.hokkaido-np.co.jp/article/532265/
|
開発 |
2021-04-12 18:13:00 |
北海道 |
北海道新聞 |
海洋放出反対の署名提出 市民団体、処理水保管を主張 |
https://www.hokkaido-np.co.jp/article/532264/
|
市民団体 |
2021-04-12 18:09:00 |
ニュース |
Newsweek |
内戦前夜、ミャンマーの緊張緩和に乗り出した中国 |
https://www.newsweekjapan.jp/stories/world/2021/04/post-96055.php
|
|
2021-04-12 18:19:40 |
IT |
週刊アスキー |
サクラバクシンオーの強キャラ感よ……!『ウマ娘 プリティーダービー』4月15日よりレジェンドレース(短距離)開催! |
https://weekly.ascii.jp/elem/000/004/051/4051187/
|
cygames |
2021-04-12 18:50:00 |
IT |
週刊アスキー |
データスコープの「顔認証型非接触入場管理チケットシステム」が日本最大級のアート見本市「アートフェア東京2021」で採用 |
https://weekly.ascii.jp/elem/000/004/051/4051136/
|
非接触 |
2021-04-12 18:40:00 |
IT |
週刊アスキー |
ソニー銀行、郵便物を介することなく即時に本人確認ができるオンライン本人確認サービス「Polarify eKYC」導入 |
https://weekly.ascii.jp/elem/000/004/051/4051092/
|
polarifyekyc |
2021-04-12 18:30:00 |
IT |
週刊アスキー |
Galaxy Watch3に新しく「血中酸素濃度測定機能」を追加 |
https://weekly.ascii.jp/elem/000/004/051/4051137/
|
galaxywatch |
2021-04-12 18:30:00 |
IT |
週刊アスキー |
東急ハンズで「楽天ポイントカード」が利用可能に |
https://weekly.ascii.jp/elem/000/004/051/4051151/
|
利用可能 |
2021-04-12 18:30:00 |
IT |
週刊アスキー |
区民ギャラリーコンサート「初夏のミニコンサート〜木琴が彩る音楽のひととき〜」 |
https://weekly.ascii.jp/elem/000/004/051/4051184/
|
音楽 |
2021-04-12 18:30:00 |
IT |
週刊アスキー |
『DQウォーク』にて『DQⅦ』イベント第6章が開始!オルゴ・デミーラ装備ふくびきも登場 |
https://weekly.ascii.jp/elem/000/004/051/4051183/
|
位置情報 |
2021-04-12 18:25:00 |
IT |
週刊アスキー |
BROWN & FRIENDSとCASETiFYの誕生10周年を記念したコレクション発売 |
https://weekly.ascii.jp/elem/000/004/051/4051143/
|
BROWNampFRIENDSとCASETiFYの誕生周年を記念したコレクション発売LINEFRIENDSは、グローバルテックファッションブランドCASETiFYとコラボし、「LINEFRIENDS×CASETiFYコレクション」を発売する。 |
2021-04-12 18:20:00 |
GCP |
Cloud Blog JA |
Cloud Spanner のマルチリージョン構成について理解する |
https://cloud.google.com/blog/ja/topics/developers-practitioners/demystifying-cloud-spanner-multi-region-configurations/
|
まとめ強力な読み込みステイル読み取りリージョン間の読み取りのレイテンシが大きい低レイテンシ確実に最新データを提供読み取りデータが最新でない可能性あり書き込みを読み取る必要があるアプリケーションには必須最新でないデータを許容でき、レイテンシの影響を受けやすいアプリケーションに最適終わりにCloudSpannerは強整合性と高可用性を両立しているだけでなく、インスタンス構成、レプリカの種類、読み取りの種類強力な読み取りとステイル読み取りに選択の幅があり、アプリケーションのレイテンシや障害に対する復元力の要件に応じた使用が可能です。 |
2021-04-12 11:00:00 |
GCP |
Cloud Blog JA |
FFN がクラウド上のフルマネージド データベースへの移行を加速した方法 |
https://cloud.google.com/blog/ja/products/databases/migrating-financial-data-to-cloud-with-database-migration-service/
|
オンプレミスインフラストラクチャからの開始Googleのデータクラウドに移行する前、当社のシステムはRackspaceでホストされていて、そのアーキテクチャはつのビジネスユニットに分割されていました。 |
2021-04-12 10:00:00 |
コメント
コメントを投稿